Code Monkey home page Code Monkey logo

import's People

Contributors

simonbrowndotje avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

import's Issues

ADR files can only be in Markdown format?

I would like to use Asciidoc for all of my documentation and ADR files. But if I make ADRs in the Asciidoc format they don't work. They either don't show up if the file-extensions is .adoc or the Asciidoc markup is ignored when I use the .md file-extension.

When I use Markdown markup with the .md extension everything works correctly.

I'm using the .war version, build 2828.

Mermaid diagrams not working

Description

The mermaid.ink url generated by Structurizr lite is incorrectly encoded and does not work. Suppose I want to include this basic mermaid diagram in an image view:

flowchart TD
    A[Christmas] -->|Get money| B(Go shopping)
    B --> C{Let me think}
    C -->|One| D[Laptop]
    C -->|Two| E[iPhone]
    C -->|Three| F[fa:fa-car Car]
flowchart TD
    A[Christmas] -->|Get money| B(Go shopping)
    B --> C{Let me think}
    C -->|One| D[Laptop]
    C -->|Two| E[iPhone]
    C -->|Three| F[fa:fa-car Car]

I can see my web browser attempts a get request to this url to get the image but it fails with the message "invalid encoded code".

https://mermaid.ink/svg/eyAiY29kZSI6ImZsb3djaGFydCBURA1cbiAgICBBW0NocmlzdG1hc10gLS0+fEdldCBtb25leXwgQihHbyBzaG9wcGluZykNXG4gICAgQiAtLT4gQ3tMZXQgbWUgdGhpbmt9DVxuICAgIEMgLS0+fE9uZXwgRFtMYXB0b3BdDVxuICAgIEMgLS0+fFR3b3wgRVtpUGhvbmVdDVxuICAgIEMgLS0+fFRocmVlfCBGW2ZhOmZhLWNhciBDYXJdIiwgIm1lcm1haWQiOnsidGhlbWUiOiJkZWZhdWx0In19

After fiddling around a bit, I found using this technique to encode the diagram worked:

mermaid_content = """
flowchart TD
    A[Christmas] -->|Get money| B(Go shopping)
    B --> C{Let me think}
    C -->|One| D[Laptop]
    C -->|Two| E[iPhone]
    C -->|Three| F[fa:fa-car Car]
"""
encoded_mermaid_content = base64.urlsafe_b64encode(mermaid_content.encode('utf-8')).decode('utf-8')

It produces this working url which successfully generates the diagram:

https://mermaid.ink/svg/CmZsb3djaGFydCBURAogICAgQVtDaHJpc3RtYXNdIC0tPnxHZXQgbW9uZXl8IEIoR28gc2hvcHBpbmcpCiAgICBCIC0tPiBDe0xldCBtZSB0aGlua30KICAgIEMgLS0-fE9uZXwgRFtMYXB0b3BdCiAgICBDIC0tPnxUd298IEVbaVBob25lXQogICAgQyAtLT58VGhyZWV8IEZbZmE6ZmEtY2FyIENhcl0K

I'm using the latest structurizr lite docker image.

Steps to reproduce

  1. Include a valid mermaid diagram file in your structurizr project.
  2. Include a basic image view like so:
    image myComponent{
    mermaid codeDiagrams/mermaidDiagram.md
    }
  3. Start Structurizr lite and attempt to examine the image view.

Screenshot

No response

Code sample

No response

Configuration

No response

Severity

Minor

Priority

Low

Resolution

I have no budget and there's no rush, please fix this for free

More information

No response

Support for ADRs created with Asciidoc

Description

With Structurizr documentation supporting asciidoc, it would be nice if the Adrs also supported this format.

The DSL Language reference states that this is supported, but it seems that a custom class would need to be created.

The !adrs keyword can be used to attach Markdown/AsciiDoc ADRs to the parent context (either the workspace, a software system, or a container).

Priority

Low

Resolution

I have no budget and there's no rush, please add this feature for free

More information

No response

SVG image cannot be displayed in Documentation or Decisions page

Description

[Foo](images/foo.svg)

embed svg with above syntax was not supported, in Documentation or Decisions page.

Can we embed SVG using the same approach as PNG images?
Something like convert them to base64 string:

<img alt="" src="data:image/svg+xml;base64,PHN2ZyBob3N0PS...+" />

Steps to reproduce

  1. Create a md file in the docs or adrs directory.
  2. Embed a svg image: [Foo](images/foo.svg)
  3. Refresh the browser, you cannot see the image.

Screenshot

No response

Code sample

No response

Configuration

No response

Severity

Minor

Priority

Low

Resolution

I have no budget, please fix this for free

More information

No response

Date of ADRs can't be changed from UTC

Description

When creating an ADR with a specific date in the Markdown file, I expect the same date to show up when rendered in Structurizr Lite's Decisions views. However, the date shown is one day earlier.

Steps to reproduce

  1. Create an ADR in Markdown format with a specific date using ADR Tools (or manually).
  2. View the ADR in Structurizr Lite.
  3. Note that the date listed in Structurizr Lite is one day earlier than that listed in the ADR Markdown file.

Screenshot

ADR Markdown files

image

image

Structurizr Lite Decisions view

image

Please excuse the odd numeric sequencing. I'm creating these ADRs retroactively, and not necessarily in chronological order.

Code sample

No response

Configuration

No response

Severity

Minor

Priority

Low

Resolution

I have no budget, please fix this for free

More information

No response

Recursive import of documentation

Issue

When using the DefaultDocumentationImporter it is not possible to import a folder structure like this:

  • docs
    • 01-introduction-and-goals
      • 01-introduction-and-goals.md
      • someAsset.png
      • anotherAsset.png

DefaultDocumentationImporter requires the files to be in the same (flat) directory.

Motivation

I'd like to be able to group assets referenced in a documentation chapter in a folder next to the actual document. This would also enable advanced workflows on Git level (e.g. define a chapter (=folder) owner as default reviewer if a given folder path was changed).

Solution Proposal

Support recursive documentation import in the default importer.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.