Comments (9)
I added new feature in v0.9.0.
You can override configs for each block. If you set a part of the settings, another part will be set to the default value.
<!-- termynal: {"prompt_literal_start": ["$", ">>>", "PS >"], title: shell} -->
```
PS > python
>>> import json
```
from termynal.py.
I admire you working to make this just right. That looks very good! I find the default MacOS buttons to be too distracting when the focus should be on the code. The position of those buttons looks good, but for Windows/Linux, I would expect at least a X
to close.
You don't have to implement my preferences, of course, but FWIW, here is the minimalist approach I took, and the pertinent CSS.
[data-termynal]:before {
content: '- ⛶ X';
color: var(--termynal-color-text-subtle);
top: 5px;
right: 7px;
left: unset;
width: unset;
background: unset;
-webkit-box-shadow: unset;
box-shadow: unset;
}
I appreciate your interest and effort in making these enhancements! 🤜🤛
from termynal.py.
Would you like to use your css file instead of Termynal's?
from termynal.py.
For example, I replace the MacOS-like modal buttons with standard '- ⛶ X' text.
And I replace the title "bash", with plain "shell".
And if the language is "powershell", I set the prefix to 'PS >'.
Similarly, for "python", the prefix is '>>>'.
I can add settings for this cases and you don't need to use your css
from termynal.py.
I was thinking support for external CSS files would provide the capability without so much development burden. If you can elegantly bake all that into this tool, that'd be awesome too 🤘
from termynal.py.
You can try to apply this configuration in 0.7.0.a1
markdown_extensions:
- termynal:
title: "powershell"
prompt_literal_start:
- "$"
- "PS >" # later it will be "PS >"
- ">>>"
<!-- termynal -->
```
PS > pip install termynal
---> 100%
Installed
```
Also in the future i will try to add a configuration like this for each code block.
<!-- termynal :: title:"shell" :: prompt_literal_start:["$", ">>>"] -->
For example, I replace the MacOS-like modal buttons with standard '- ⛶ X' text.
It will be later
from termynal.py.
That's dope! Yeah, being able to configure each prompt is essential, as a bash-, powershell-, or python-termynal could all exist in the same page.
Thank you!
from termynal.py.
🤩
from termynal.py.
Well... I wrote a simple code for this result. What do you think?
<!-- termynal: {"prompt_literal_start": ["$", ">>>", "PS >"], title: powershell, buttons: windows} -->
```
PS > python
>>> import json
```
from termynal.py.
Related Issues (16)
- Add "restart" and "faster" button to animation in termynal HOT 3
- Plugin crashes when a raw HTML div with `markdown` attribute is present into Markdown pages HOT 2
- Termynal and superfences compatibility HOT 23
- [Question] Support for multiline commands? HOT 14
- Support for code blocks with language specified
- Support for multiline output HOT 1
- Formatting issue with `rich` panels HOT 2
- Progress bar is not responsive (or not respecting the limits) HOT 2
- Regular expression error in FENCED_BLOCK_RE HOT 2
- Support within lists, admonitions, and content tabs HOT 5
- Need to custom size HOT 2
- How to make it compatible with pymodwnx.snippets? HOT 2
- multi-line command issue and minify plugin HOT 2
- Animation doesn't start - fast and restart buttons do not render HOT 3
- no such file HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from termynal.py.