Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Register
  • Sign in
  • G gitlab-ce
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 1
    • Merge requests 1
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • nexedinexedi
  • gitlab-ce
  • Repository
"stack/erp5/instance-mariadb-start-clone-from-backup.sh.in" did not exist on "master"
  • gitlab-ce
  • spec
  • frontend
  • notebook
  • cells
  • code_spec.js
Find file BlameHistoryPermalink
  • Reinhold Gschweicher's avatar
    Katex render and vscode output improvements for md · a7d9d536
    Reinhold Gschweicher authored May 05, 2020
    1. Fix output of jupyter notebooks saved in VSCode
    
    VSCode uses the newer NBFormat Version 4.1 [1], which allows
    the output text entry to be a simple string.
    
    The function `rawCode` assumed NBFormat Version 3.2 [2], which requires
    the output.text object to be an array.
    
    This commit adds a special handling if the type of output.text is a
    string, then we don't need to use `join()` and can just return the
    string.
    
    Fixes: https://gitlab.com/gitlab-org/gitlab/-/issues/212837
    
    [1] https://nbformat.readthedocs.io/en/latest/format_description.html
    [2] https://ipython.org/ipython-doc/3/notebook/nbformat.html
    
    2. Handle katex render error in ipython markdown
    
    When a formula brings katex to its knees the whole cell is dropped.
    Instead of just dropping continue on and leave the unrendered formula in
    the cell.
    
    Partially fixes: https://gitlab.com/gitlab-org/gitlab/-/issues/216744
    
    3. Render listitems with Katex in ipython markdown
    
    Add a renderer callback for list items. Not only paragraphs should have
    the honor to have math formulas rendered with Katex. Also listitems of
    bullet points and enumerations should have this honor.
    
    Fixes: https://gitlab.com/gitlab-org/gitlab/-/issues/216741
    
    4. Get the tick `'` back to pass it to Katex
    
    When rendering IPython notebook markdown cells the formulas are passed
    to Katex. Before that the raw string is passed to marked.js to handle
    HTML forbidden characters. One of these characters is the `'`. This
    character is often used in math formulas and the replacement `&#39` is
    not well received by Katex.
    
    Fixes: https://gitlab.com/gitlab-org/gitlab/-/issues/216744
    a7d9d536
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7