ntno / mkdocs-terminal Goto Github PK
View Code? Open in Web Editor NEWmonospace theme for MkDocs
Home Page: https://ntno.github.io/mkdocs-terminal/
License: MIT License
monospace theme for MkDocs
Home Page: https://ntno.github.io/mkdocs-terminal/
License: MIT License
base on max content length?
https://www.nngroup.com/articles/change-the-color-of-visited-links/
could be an opt-in feature
consider:
ensure works for alternate palettes
need at least the version that has namespace feature
sometimes shows #, ##, and ### in toc
other times just # and ##
is it just depth that matters? not the actual number of hashes?
see https://webaim.org/blog/alt-text-and-linked-images/
comment from article:
Title is intended to provide supplementary information. If title is necessary for accessibility, then it is therefor NOT supplementary.
and
see https://usability.yale.edu/web-accessibility/articles/images
Image links should describe the purpose of the link, and must never describe the image.
and
https://usability.yale.edu/web-accessibility/articles/links
Image Links
In general, content editors should avoid using images as links. If an image functions as a link, the image must have alt text that conveys the location and purpose of the link. The alt text should not describe the image. Treat image links as links, not as images.
also:
we should add a built-in high contrast color palette
the colors should meet WCAG guidelines
tasks:
add section to
./documentation/docs/configuration/extensions/py-mdown-extensions.md
add to supported list in main index
./documentation/docs/configuration/extensions/index.md
example usage:
https://github.com/ntno/mkdocs-terminal/blob/main/documentation/mkdocs.yml#L45-L62
https://github.com/ntno/mkdocs-terminal/blob/main/documentation/docs/tile-grid/index.md?plain=1#L95-L99
leverage Terminal.css alert class?
check existing palettes to see which conform to WCAG contrast guidelines
tasks:
see #108 for details on reasoning
https://terminalcss.xyz/ has nested list examples but currently they don't render correctly from markdown
yale accessibility guidelines say to avoid opening links in new window/tab
https://yale.app.box.com/s/ochc2c7zzhsj4wuk6fv41hbk5w8vhxt5
is this the general consensus? if so should update docs
is this possible?
do we need to create a dist and install that using pip?
is it worth it given that the watch functionality won't really be watching the theme files under development?
needs further investigation
invert terminal_prompt feature flag
see https://github.com/ntno/mkdocs-demo for example
new s3 bucket for each PR, deploy doc site to temporary website, teardown bucket when PR is closed
when an ordered list is added to a markdown page, any footnotes start counting at the next number following the end of the ordered list
when a unordered list is included, footnotes start at the number 1:
when a ordered list is included, footnotes start where the ordered list left off:
with ordered list:
1. First item
1. Second item
1. Third item
1. Indented item
1. Indented item
1. Fourth item
points back to https://ntno.github.io/
reran 1.0.1 release job and it passed... seems incorrect
overview page for configuration section doesn't accurately describe section
currently the page focuses on just a subsection of the hideable component features
https://github.com/ntno/mkdocs-terminal/blob/484da138de9bb04f51b418790523648639744b2b/documentation/docs/configuration/index.md
I would like to be able to enter markdown for a tile caption and have it be rendered in the final tile grid
if the tile.caption is markdown then it should render correctly when md_in_html extension is enabled
ex:
tile.caption: Figure 8, *Misc. Project Notes*, pages 82, 83.
then 'Misc. Project Notes' should be in italics
current workaround is to use html tags
ex:
tile.caption: Figure 8, <i>Misc. Project Notes</i>, pages 82, 83.
https://ntno.github.io/mkdocs-terminal/navigation/section-indexes/
pictures first, just like with the other overview pages (tile grid, configuration, search, revision, etc.)
we should add translation support so that the theme can be used for sites in languages other than english
https://www.mkdocs.org/dev-guide/translations/
currently we load from MkDocs Page metadata
would be nice to be able to load from outside source file / api
i should be able to provide a markdown file name as the tile link_href
run link_href value through mkdocs url filter?
have been providing a relative "directory" link. ie ./gruvbox-dark/
instead of ./gruvbox-dark.md
dark section title is confusing --- too similar to when a page is active (dark italics)
The theme supports mkdocs-git-revision-date-plugin
however there are no instructions on how to set it up
add plugins/ folder with index and git revision page
(similar to extensions/ docs)
todo stub
not sure we should say 'supported plugins'.... we don't necessarily want to promise to always and forever work with the listed plugins.
not necessarily willing to fix any issue that crops up related to plugin.
change to 'tested'? something to just indicate that it was reviewed and will probably work
there is probably a template for this
when pytests run on windows-latest github action runner i get the following error:
self = <tidylib.tidy.Tidy object at 0x00000200870C3070>
lib_names = ['libtidy', 'libtidy.so', 'libtidy-0.99.so.0', 'cygtidy-0-99-0', 'tidylib', 'libtidy.dylib', ...]
def __init__(self, lib_names=None):
self._tidy = None
if lib_names is None:
lib_names = ctypes.util.find_library('tidy') or LIB_NAMES
if isinstance(lib_names, str):
lib_names = [lib_names]
for name in lib_names:
try:
self._tidy = load_library(name)
break
except OSError:
continue
if self._tidy is None:
> raise OSError(
"Could not load libtidy using any of these names: "
+ ",".join(lib_names))
E OSError: Could not load libtidy using any of these names: libtidy,libtidy.so,libtidy-0.99.so.0,cygtidy-0-99-0,tidylib,libtidy.dylib,tidy
.tox\py\lib\site-packages\tidylib\tidy.py:97: OSError
(see attached for full log)
install tidy with soop:
- if: ${{ matrix.platform == 'windows-latest' }}
name: Install scoop (Windows)
uses: MinoruSekine/setup-scoop@main
with:
scoop_update: false
- if: ${{ matrix.platform == 'windows-latest' }}
name: Install test requirements (windows)
run: |
scoop install tidy
then run pytest from tox.ini:
commands =
pytest {tty:--color=yes} tests {posargs}
from scoop install:
Installing 'tidy' (5.8.0) [64bit] from main bucket
Downloading https://github.com/htacg/tidy-html5/releases/download/5.8.0/tidy-5.8.0-win64.zip (1.3 MB)...
Checking hash of tidy-5.8.0-win64.zip ... ok.
Extracting tidy-5.8.0-win64.zip ... done.
Linking ~\scoop\apps\tidy\current => ~\scoop\apps\tidy\5.8.0
Creating shim for 'tidy'.
'tidy' (5.8.0) was installed successfully!
HTML Tidy for Windows version 5.8.0
pages can get quite long and it takes a lot of scrolling to get back up to the table of contents and the side nav.
there should be an option to add a "go to top" button which would move the screen to the table of contents and/or top of the page
just get '404 Not Found' without terminal theme
search results should update as more text is entered in search bar
<meta name="robots" content="noindex">
what is this for / what does it do
do we need it in the theme? should it be optional?
example use cases:
unit scenario
when tile.j2 macro is used to create a UI component but the required tile attributes are not included, no UI component is rendered
integration scenario
when palette: dark
is set in mkdocs.yml, then dark.css
should be loaded
i don't have a lot of experience doing automated testing for frontend projects so any help here would be extremely appreciated. even just a pointer in the direction of a simple example project would be helpful.
current todos:
move developer notes elsewhere
would appreciate a second set of eyes since i copied most of this from mkdocs and mkdocs-material
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.