I am working on a sphinx documentation and i am facing following problem at the moment:
I am using roles for different display options. Now i wanted to add font-awesome logos to a certain text within the role, but the placeholders i use don´t work in the role definition. Here an example:
:ver:`|Cubes| random text`
ver is my class and |Cubes| is the placeholder for the font-awesome logo.
The problem is, that the placeholder requires a white-space before and after the | but for the role definition there can´t be a white-space right after or before the `.
Is there a way to solve this without creating a different role for every logo i use in my documentation?
Thanks for every Answer :)
Nope. From Interpreted Text:
Interpreted text is text that is meant to be related, indexed, linked, summarized, or otherwise processed, but the text itself is typically left alone.
See Inline markup recognition rules for details.
As an aside, what you call "placeholders" are substitions in reST terminology.
Related
At my company, for templates for Vue.js, we write components in separate Blade files. The problem I have is that HTML code is not highlighted in those files. Whole HTML code is written inside script tags which has the syntax:
<script type="x/templates" id="nameOfComponent">.
By deleting the type attribute, highlighting starts working correctly. I have searched a little bit and found that there are different types, but I have never seen one like the one above (the closest one I saw is text/x-template and highlighting works with it). Now, as I am not allowed to change these kinds of things, I have a couple of questions (also, I have to mention I'm new to JavaScript and PHP):
If this is not predefined type, are user-defined types supported?
If so, is there any extension for VS code which would highlight HTML part of the code?
If user-defined types are not the right solution, which one would be the best solution for me?
try:
https://github.com/vuejs/vetur
Pretty sure it should support vue template syntax highlighting.
We are using Quill for basic formatting (Bold, Italic, Link, BlockQuote). However Quill.min.js is the largest file that we've in our page.
We are looking to cut the size of the file by including the necessary modules only (for e.g. remove Syntax and Formula).
What is the way to get them removed? Do we need to setup the environment as described in Development page? Would it be possible to comment or remove the codes in quill.js? Appreciate any guidance
You can use quill.core.js and quill.core.css instead which will not have extra modules like Syntax and Formula. These files are not minified for you however. If you want to customize further then you will have to build Quill yourself.
When i create a new api documentation in apiary.io, the rendered document and navigation shows structural level which are not visible in the editor:
INTRODUCTION
REFERENCE
Default
While I can accept the highest levels to generated magically, I would like to rename and duplicate the second level.
How do I do it? How is it called? It has CSS classes resourceGroupName but this does not appear to be the name.
Seems like I have overseen that some words that look like normal text are in fact keywords for the apiblueprint parser. One of them is Group, explained here: https://docs.apiary.io/api_101/api_blueprint_tutorial/#resource-groups
I am trying to write a jekyll plugin that will take a normal markdown file and provide some extra functionality on top of it. In particular, I need to do some (not actually) fancy things with tables. I know you can write straight HTML into a markdown file, but there is a requirement that the content folks don't want to / can't edit HTML.
As an extra wrench in the works, the mobile layout has a UX requirement that I essentially have to render the table as a group of divs as opposed to a table.
My initial thought was to pass the {{page.content}} variable to a ruby function extending Liquid::Tag. From there I was planning on parsing the markdown file and either:
1. If normal non-table markdown, use as normal
2. If table markdown, look for custom identifier in markdown, do what needs to be done (e.g. add class, etc)
If I do something like this:
def render(context)
content = Liquid::Template.parse(#markup).render context
end
It renders the context as a normal markdown file. However, I want to break up the context variable and work with the pieces before rendering. I've tried a few different approaches that I've gotten from the jekyll docs and Stack Overflow and gotten nowhere.
Does anyone have any experience with this? I am heading down the right path? For what it's worth, Ruby/Jekyll/Liquid is fairly new to me, so if you think I may have missed something fairly basic and obvious then please let me know.
A markdown table tool for editors !
markdownify your table in http://www.tablesgenerator.com/markdown_tables
paste the markdown result in http://prose.io/
done
I don't know other way to simplify editor's work on Jekyll, but I'll be very interested in earing from your project. Good luck.
I am understanding this better but still not there yet.
I have a notes document with a rich text field. I want to edit it in Xpages, so that the user can enter text for an email that an agent will generate. The idea is that the user should be able to enter styled text, hopefully including pasted graphics, and this is saved to the rich text field in such a way that a later agent can copy that field to the body of an email.
On the form I have checked the field "Store contents as HTML and MIME.
In the Xpage I have bound the CKEditor directly to the field (can bind it to a scope variable if necessary).
The code in my agent is as follows:
Set rtItmFrm = emlDoc.getFirstItem("Body")
Set rtItmTo = New NotesRichTextItem(mail,"Body")
Set rtItmTo = rtItmFrm.Copyitemtodocument(mail,"Body")
Any further suggestions on reading up on MIME/CKEditor etc would also be much appreciated.
Bryan
=========================================================================
I just discovered how to modify the CKEditor in Xpages (the Rich Text Control). I have the full menu and one or two more things turned out. However, I am really puzzled by how it treats HTML. I would like to put a template for a nice HTML email (like a newsletter). Anything even a little complicated it munges and the output is messed up.
I read enough online to understand that it is not supposed to be a HTML editor, but I am really having trouble getting the results I want. I would love to put some basic skeleton HTML in there, but everything but the simplest code doesn't work.
Is there anyway to import HTML and it not get messed up using this editor?
as Per and Stephan said, Have a look at ACF filtering that is 'server side' (This is not related to CKEditor itself, but it is related to XPages).
If you have a look at the inputRichText control you will see 2 properties.
htmlFilter
htmlFilterIn
These properties determine how to filter Html on the way in to your data, and also on the way out.
This can be used to strip styling out, and also to prevent dangerous tags like some bad code here etc.
By Default the htmlFilter is set ACF (Active Content Filtering) if you look at the default rules, you will see it strips things like 'margin' out.
see /properties/acf-config.xml-sample
There is a filter called 'identity' which means don't filter anything, however beware if you use this you are not protected from and maliciously entered html.
You should look into defining your own set of rules for your ACF filter, this way you can choose which elements to remove. There is a section in Mastering XPages book about this.
If you still have any trouble, then there are some settings in CKEditor config which also control ACF (totally separate to XPages server side)
I don't think CKE changes the HTML, it is the writing back to a RT field.
Try and bind your RichText Editor to a scoped variable instead of a RichText field. This way you have access to the raw HTML and can use that to generate a MIME email. You might want to have a look at Mustache for mail merge.
Use this article series as starter how to prepare CK editor to make this possible.
And as Per mentioned: check the filtering.