d3graph 3.1.0__tar.gz → 3.1.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.
- {d3graph-3.1.0 → d3graph-3.1.2}/MANIFEST.in +1 -0
- {d3graph-3.1.0/d3graph.egg-info → d3graph-3.1.2}/PKG-INFO +1 -1
- {d3graph-3.1.0 → d3graph-3.1.2}/d3graph/__init__.py +1 -1
- {d3graph-3.1.0 → d3graph-3.1.2}/d3graph/d3graph.py +2 -2
- d3graph-3.1.0/d3graph/d3js/index.html.j2 → d3graph-3.1.2/d3graph/d3js/d3graph.html.j2 +21 -6
- d3graph-3.1.2/d3graph/d3js/logo.txt +1 -0
- {d3graph-3.1.0 → d3graph-3.1.2}/d3graph/d3js/style.css +110 -96
- {d3graph-3.1.0 → d3graph-3.1.2}/d3graph/examples.py +2 -20
- {d3graph-3.1.0 → d3graph-3.1.2/d3graph.egg-info}/PKG-INFO +1 -1
- {d3graph-3.1.0 → d3graph-3.1.2}/d3graph.egg-info/SOURCES.txt +3 -2
- {d3graph-3.1.0 → d3graph-3.1.2}/LICENSE +0 -0
- {d3graph-3.1.0 → d3graph-3.1.2}/README.md +0 -0
- {d3graph-3.1.0 → d3graph-3.1.2}/d3graph/d3js/d3.v3.js +0 -0
- /d3graph-3.1.0/d3graph/d3js/d3graphscript.js → /d3graph-3.1.2/d3graph/d3js/d3graph.js +0 -0
- {d3graph-3.1.0 → d3graph-3.1.2}/d3graph/examples_docs.py +0 -0
- {d3graph-3.1.0 → d3graph-3.1.2}/d3graph/examples_rankings.py +0 -0
- {d3graph-3.1.0 → d3graph-3.1.2}/d3graph/examples_rankings_Pvalue.py +0 -0
- {d3graph-3.1.0 → d3graph-3.1.2}/d3graph.egg-info/dependency_links.txt +0 -0
- {d3graph-3.1.0 → d3graph-3.1.2}/d3graph.egg-info/requires.txt +0 -0
- {d3graph-3.1.0 → d3graph-3.1.2}/d3graph.egg-info/top_level.txt +0 -0
- {d3graph-3.1.0 → d3graph-3.1.2}/pyproject.toml +0 -0
- {d3graph-3.1.0 → d3graph-3.1.2}/setup.cfg +0 -0
|
@@ -98,7 +98,7 @@ class d3graph:
|
|
|
98
98
|
# Set paths
|
|
99
99
|
self.config['curpath'] = os.path.dirname(os.path.abspath(__file__))
|
|
100
100
|
self.config['d3_library'] = os.path.abspath(os.path.join(self.config['curpath'], 'd3js/d3.v3.js'))
|
|
101
|
-
self.config['d3_script'] = os.path.abspath(os.path.join(self.config['curpath'], 'd3js/
|
|
101
|
+
self.config['d3_script'] = os.path.abspath(os.path.join(self.config['curpath'], 'd3js/d3graph.js'))
|
|
102
102
|
self.config['css'] = os.path.abspath(os.path.join(self.config['curpath'], 'd3js/style.css'))
|
|
103
103
|
|
|
104
104
|
def _clean(self, clean_config: bool = True) -> None:
|
|
@@ -908,7 +908,7 @@ class d3graph:
|
|
|
908
908
|
jinja_env = Environment(loader=PackageLoader(package_name=__name__, package_path='d3js'))
|
|
909
909
|
except:
|
|
910
910
|
jinja_env = Environment(loader=PackageLoader(package_name='d3graph', package_path='d3js'))
|
|
911
|
-
index_template = jinja_env.get_template('
|
|
911
|
+
index_template = jinja_env.get_template('d3graph.html.j2')
|
|
912
912
|
html = index_template.render(content)
|
|
913
913
|
|
|
914
914
|
index_file = self.config['filepath']
|
|
@@ -19,11 +19,23 @@
|
|
|
19
19
|
HTML into a page that supplies its own button chrome but still wants
|
|
20
20
|
the slider). -->
|
|
21
21
|
{% if show_controls or max_slider > min_slider %}
|
|
22
|
-
<div class="header-row">
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
<div class="
|
|
22
|
+
<div class="header-row">
|
|
23
|
+
|
|
24
|
+
<div class="header-row-left">
|
|
25
|
+
<div class="top-panel-left">
|
|
26
|
+
<a href="https://d3blocks.github.io/d3blocks/" title="D3Blocks">
|
|
27
|
+
<img src="{% include 'logo.txt' %}" alt="D3Blocks" style="width:150px;height:auto;display:block;pointer-events:auto" />
|
|
28
|
+
</a>
|
|
29
|
+
</div>
|
|
26
30
|
</div>
|
|
31
|
+
|
|
32
|
+
<div class="header-row-left">
|
|
33
|
+
<div class="search-wrap">
|
|
34
|
+
<input class="search-input" id="searchInput" type="search" placeholder="Find a node…" autocomplete="off" spellcheck="false" />
|
|
35
|
+
<div class="search-results" id="searchResults"></div>
|
|
36
|
+
</div>
|
|
37
|
+
</div>
|
|
38
|
+
|
|
27
39
|
{% if max_slider > min_slider %}
|
|
28
40
|
{{ slider_comment_start }}
|
|
29
41
|
<div class="slider-container">
|
|
@@ -37,11 +49,13 @@
|
|
|
37
49
|
{{ slider_comment_stop }}
|
|
38
50
|
{% endif %}
|
|
39
51
|
{% if show_controls %}
|
|
52
|
+
|
|
40
53
|
<div class="top-panel">
|
|
41
54
|
<button id="darkModeSwitch" class="button-switch">{% if dark_mode %}☀ Light Mode{% else %}🌙 Dark Mode{% endif %}</button>
|
|
42
55
|
<button id="edgeToggleButton" class="button-switch">Hide Edges</button>
|
|
43
56
|
<button id="densityToggleButton" class="button-switch">{% if show_density %}Hide Density{% else %}Show Density{% endif %}</button>
|
|
44
57
|
</div>
|
|
58
|
+
|
|
45
59
|
{% endif %}
|
|
46
60
|
</div>
|
|
47
61
|
{% endif %}
|
|
@@ -50,6 +64,7 @@
|
|
|
50
64
|
<!-- Side panel: data/image export actions, previously loose buttons in the
|
|
51
65
|
top-panel row  grouped here since they're one-off actions rather than
|
|
52
66
|
persistent view controls, and it keeps the top-panel row shorter. -->
|
|
67
|
+
|
|
53
68
|
<div class="stats-panel collapsed" id="exportPanel">
|
|
54
69
|
<div class="stats-panel-title">Export<span class="stats-panel-toggle" aria-hidden="true"><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><polyline points="6 9 12 15 18 9"></polyline></svg></span></div>
|
|
55
70
|
<div class="stats-panel-body">
|
|
@@ -77,7 +92,7 @@
|
|
|
77
92
|
<!-- Layout panel (Force-directed / Circular / Grid) removed from the UI -
|
|
78
93
|
circular/grid felt too static to be useful. The underlying setLayout()/
|
|
79
94
|
|
|
80
|
-
layoutCircular()/layoutGrid() functions are still in
|
|
95
|
+
layoutCircular()/layoutGrid() functions are still in d3graph.js,
|
|
81
96
|
just unwired, in case this is worth revisiting later. -->
|
|
82
97
|
|
|
83
98
|
<!-- Side panel: interactively tune the force simulation -->
|
|
@@ -148,7 +163,7 @@
|
|
|
148
163
|
|
|
149
164
|
<script>
|
|
150
165
|
{% include "d3.v3.js" %}
|
|
151
|
-
{% include "
|
|
166
|
+
{% include "d3graph.js" %}
|
|
152
167
|
|
|
153
168
|
graph = {{ json_data }}
|
|
154
169
|
|