Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 30cad0c

Browse filesBrowse files
authored
Apigen recursive (plotly#2243)
* using sphinx-apidoc for generating the hierarchy of doc pages * playing with templates * autodoc for sphinx * blacken * also modified property functions * changed :py:class: to :class: * blacken * revert changes to package-lock * some fixes * fix * removed module from trace page * revert template change * title in template
1 parent ce4fec8 commit 30cad0c
Copy full SHA for 30cad0c

File tree

Expand file treeCollapse file tree

403 files changed

+9142
-8397
lines changed
Open diff view settings
Filter options

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Dismiss banner
Expand file treeCollapse file tree

403 files changed

+9142
-8397
lines changed
Open diff view settings
Collapse file

‎.circleci/config.yml‎

Copy file name to clipboardExpand all lines: .circleci/config.yml
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -409,7 +409,7 @@ jobs:
409409
cd ../../../doc
410410
fi
411411
echo 'export PATH="/home/circleci/project/doc/node_modules/.bin:$PATH"' >> $BASH_ENV
412-
sudo apt-get install -y poppler-utils libxtst6 xvfb libgtk2.0-0 libgconf-2-4 libnss3 libasound2
412+
sudo apt-get install -y poppler-utils libxtst6 xvfb libgtk2.0-0 libgconf-2-4 libnss3 libasound2 rename
413413
cd ..
414414
415415
- save_cache:
Collapse file

‎doc/apidoc/Makefile‎

Copy file name to clipboardExpand all lines: doc/apidoc/Makefile
+5Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,10 @@ help:
1515

1616
# Catch-all target: route all unknown targets to Sphinx using the new
1717
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
18+
# For sphinx-apidoc the first positional path is the module to document
19+
# then all the other ones are paths to exclude for the doc generation
1820
%: Makefile
21+
sphinx-apidoc -o generated ../../packages/python/plotly/plotly ../../packages/python/plotly/plotly/validators ../../packages/python/plotly/plotly/tests ../../packages/python/plotly/plotly/matplotlylib/ ../../packages/python/plotly/plotly/offline ../../packages/python/plotly/plotly/api
1922
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
23+
rename 's/graph_objs/graph_objects/' _build/html/*.html _build/html/generated/*.html
24+
sed -i 's/graph_objs/graph_objects/g' _build/html/*.html _build/html/generated/*.html
Collapse file

‎doc/apidoc/_templates/class.rst‎

Copy file name to clipboardExpand all lines: doc/apidoc/_templates/class.rst
-15Lines changed: 0 additions & 15 deletions
This file was deleted.
Collapse file

‎doc/apidoc/_templates/trace.rst‎

Copy file name to clipboardExpand all lines: doc/apidoc/_templates/trace.rst
+1-1Lines changed: 1 addition & 1 deletion
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
.. automethod:: __init__
1111
{% endblock %}
1212

13-
1413
:mod:`{{module}}`.{{objname.lower()}}
1514
{{ underline }}================================
1615

@@ -20,6 +19,7 @@
2019

2120
.. automodule:: plotly.graph_objects.{{ objname.lower() }}
2221
:members:
22+
:undoc-members:
2323

2424

2525
.. raw:: html
Collapse file

‎doc/apidoc/plotly.graph_objects.rst‎

Copy file name to clipboardExpand all lines: doc/apidoc/plotly.graph_objects.rst
+1-2Lines changed: 1 addition & 2 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
`plotly.graph_objects`: low-level interface to figures, traces and layout
44
=========================================
55

6-
.. currentmodule:: plotly.graph_objects
6+
.. currentmodule:: plotly.graph_objs
77

88
:mod:`plotly.graph_objects` contains the building blocks of plotly :class:`Figure`: traces
99
(:class:`Scatter`, :class:`Bar`, ...) and :class:`Layout`
@@ -31,7 +31,6 @@ Layout
3131
Layout
3232

3333

34-
3534
Simple charts
3635
--------------
3736

Collapse file

‎packages/javascript/plotlywidget/package-lock.json‎

Copy file name to clipboardExpand all lines: packages/javascript/plotlywidget/package-lock.json
+2-2Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Collapse file

‎packages/python/plotly/_plotly_utils/basevalidators.py‎

Copy file name to clipboardExpand all lines: packages/python/plotly/_plotly_utils/basevalidators.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2421,7 +2421,7 @@ def description(self):
24212421
"""\
24222422
The '{plotly_name}' property is an instance of {class_str}
24232423
that may be specified as:
2424-
- An instance of {module_str}.{class_str}
2424+
- An instance of :class:`{module_str}.{class_str}`
24252425
- A dict of string/value properties that will be passed
24262426
to the {class_str} constructor
24272427
Collapse file

‎packages/python/plotly/codegen/datatypes.py‎

Copy file name to clipboardExpand all lines: packages/python/plotly/codegen/datatypes.py
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ def __init__(self"""
293293
(
294294
f"arg",
295295
f"dict of properties compatible with this constructor "
296-
f"or an instance of {class_name}",
296+
f"or an instance of :class:`{class_name}`",
297297
)
298298
]
299299

@@ -321,7 +321,7 @@ def __init__(self"""
321321
raise ValueError(\"\"\"\\
322322
The first argument to the {class_name}
323323
constructor must be a dict or
324-
an instance of {class_name}\"\"\")
324+
an instance of :class:`{class_name}`\"\"\")
325325
326326
# Handle skip_invalid
327327
# -------------------
Collapse file

‎packages/python/plotly/codegen/figure.py‎

Copy file name to clipboardExpand all lines: packages/python/plotly/codegen/figure.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ class {fig_classname}({base_classname}):\n"""
9494
def __init__(self, data=None, layout=None,
9595
frames=None, skip_invalid=False, **kwargs):
9696
\"\"\"
97-
Create a new {fig_classname} instance
97+
Create a new :class:{fig_classname} instance
9898
9999
Parameters
100100
----------
Collapse file

‎packages/python/plotly/codegen/utils.py‎

Copy file name to clipboardExpand all lines: packages/python/plotly/codegen/utils.py
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -941,7 +941,7 @@ def get_constructor_params_docstring(self, indent=12):
941941
f"{subtype_node.name_datatype_class}"
942942
)
943943
subtype_description = (
944-
f"A tuple of {class_name} instances or "
944+
f"A tuple of :class:`{class_name}` instances or "
945945
"dicts with compatible properties"
946946
)
947947
elif subtype_node.is_compound:
@@ -958,7 +958,7 @@ def get_constructor_params_docstring(self, indent=12):
958958
)
959959

960960
subtype_description = (
961-
f"{class_name} instance or dict with compatible properties"
961+
f":class:`{class_name}` instance or dict with compatible properties"
962962
)
963963
else:
964964
subtype_description = ""

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.