Skip to content

Commit

Permalink
add mermaid
Browse files Browse the repository at this point in the history
  • Loading branch information
jdonszelmann committed Jun 3, 2024
1 parent 2debdbf commit f08c53d
Show file tree
Hide file tree
Showing 129 changed files with 301,109 additions and 1 deletion.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
# will have compiled files and executables
debug/
target/
doc/

# Remove Cargo.lock from gitignore if creating an executable, leave it for libraries
# More information here https://doc.rust-lang.org/cargo/guide/cargo-toml-vs-cargo-lock.html
Expand Down
29 changes: 29 additions & 0 deletions scopegraphs-render-docs/doc/js/Diagram.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
import { DetailedError } from './utils';
export declare type ParseErrorFunction = (err: string | DetailedError | unknown, hash?: any) => void;
/**
* An object representing a parsed mermaid diagram definition.
* @privateRemarks This is exported as part of the public mermaidAPI.
*/
export declare class Diagram {
text: string;
type: string;
parser: any;
renderer: any;
db: import("./diagram-api/types").DiagramDb;
private detectError?;
constructor(text: string);
parse(): void;
render(id: string, version: string): Promise<void>;
getParser(): any;
getType(): string;
}
/**
* Parse the text asynchronously and generate a Diagram object asynchronously.
* **Warning:** This function may be changed in the future.
* @alpha
* @param text - The mermaid diagram definition.
* @returns A the Promise of a Diagram object.
* @throws {@link UnknownDiagramError} if the diagram type can not be found.
* @privateRemarks This is exported as part of the public mermaidAPI.
*/
export declare const getDiagramFromText: (text: string) => Promise<Diagram>;
27 changes: 27 additions & 0 deletions scopegraphs-render-docs/doc/js/accessibility.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
/**
* Accessibility (a11y) functions, types, helpers
* @see https://www.w3.org/WAI/
* @see https://www.w3.org/TR/wai-aria-1.1/
* @see https://www.w3.org/TR/svg-aam-1.0/
*
*/
import { D3Element } from './mermaidAPI';
/**
* Add role and aria-roledescription to the svg element
*
* @param svg - d3 object that contains the SVG HTML element
* @param diagramType - diagram name for to the aria-roledescription
*/
export declare function setA11yDiagramInfo(svg: D3Element, diagramType: string | null | undefined): void;
/**
* Add an accessible title and/or description element to a chart.
* The title is usually not displayed and the description is never displayed.
*
* The following charts display their title as a visual and accessibility element: gantt
*
* @param svg - d3 node to insert the a11y title and desc info
* @param a11yTitle - a11y title. null and undefined are meaningful: means to skip it
* @param a11yDesc - a11y description. null and undefined are meaningful: means to skip it
* @param baseId - id used to construct the a11y title and description id
*/
export declare function addSVGa11yTitleDescription(svg: D3Element, a11yTitle: string | null | undefined, a11yDesc: string | null | undefined, baseId: string): void;
1 change: 1 addition & 0 deletions scopegraphs-render-docs/doc/js/accessibility.spec.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export {};
145 changes: 145 additions & 0 deletions scopegraphs-render-docs/doc/js/arc-c50f0902.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

85 changes: 85 additions & 0 deletions scopegraphs-render-docs/doc/js/arc-f7872e1e.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions scopegraphs-render-docs/doc/js/array-2ff2c7a6.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions scopegraphs-render-docs/doc/js/array-b7dcf730.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

31 changes: 31 additions & 0 deletions scopegraphs-render-docs/doc/js/assignWithDepth.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
export default assignWithDepth;
/**
* @function assignWithDepth Extends the functionality of {@link ObjectConstructor.assign} with the
* ability to merge arbitrary-depth objects For each key in src with path `k` (recursively)
* performs an Object.assign(dst[`k`], src[`k`]) with a slight change from the typical handling of
* undefined for dst[`k`]: instead of raising an error, dst[`k`] is auto-initialized to {} and
* effectively merged with src[`k`]<p> Additionally, dissimilar types will not clobber unless the
* config.clobber parameter === true. Example:
*
* ```js
* let config_0 = { foo: { bar: 'bar' }, bar: 'foo' };
* let config_1 = { foo: 'foo', bar: 'bar' };
* let result = assignWithDepth(config_0, config_1);
* console.log(result);
* //-> result: { foo: { bar: 'bar' }, bar: 'bar' }
* ```
*
* Traditional Object.assign would have clobbered foo in config_0 with foo in config_1. If src is a
* destructured array of objects and dst is not an array, assignWithDepth will apply each element
* of src to dst in order.
* @param {any} dst - The destination of the merge
* @param {any} src - The source object(s) to merge into destination
* @param {{ depth: number; clobber: boolean }} [config={ depth: 2, clobber: false }] - Depth: depth
* to traverse within src and dst for merging - clobber: should dissimilar types clobber (default:
* { depth: 2, clobber: false }). Default is `{ depth: 2, clobber: false }`
* @returns {any}
*/
declare function assignWithDepth(dst: any, src: any, config?: {
depth: number;
clobber: boolean;
} | undefined): any;
Loading

0 comments on commit f08c53d

Please sign in to comment.