1 line
62 KiB
Plaintext
1 line
62 KiB
Plaintext
{"version":3,"file":"requirementDiagram-59bd3776.js","sources":["../src/diagrams/requirement/parser/requirementDiagram.jison","../src/diagrams/requirement/requirementDb.js","../src/diagrams/requirement/styles.js","../src/diagrams/requirement/requirementMarkers.js","../src/diagrams/requirement/requirementRenderer.js","../src/diagrams/requirement/requirementDiagram.ts"],"sourcesContent":["/** mermaid\n * https://knsv.github.io/mermaid\n * (c) 2015 Knut Sveidqvist\n * MIT license.\n */\n%lex\n%options case-insensitive\n\n%x string\n%x token\n%x unqString\n%x open_directive\n%x type_directive\n%x arg_directive\n%x close_directive\n%x acc_title\n%x acc_descr\n%x acc_descr_multiline\n%%\n\\%\\%\\{ { this.begin('open_directive'); return 'open_directive'; }\n<open_directive>((?:(?!\\}\\%\\%)[^:.])*) { this.begin('type_directive'); return 'type_directive'; }\n<type_directive>\":\" { this.popState(); this.begin('arg_directive'); return ':'; }\n<type_directive,arg_directive>\\}\\%\\% { this.popState(); this.popState(); return 'close_directive'; }\n<arg_directive>((?:(?!\\}\\%\\%).|\\n)*) return 'arg_directive';\n\n\"title\"\\s[^#\\n;]+ return 'title';\naccTitle\\s*\":\"\\s* { this.begin(\"acc_title\");return 'acc_title'; }\n<acc_title>(?!\\n|;|#)*[^\\n]* { this.popState(); return \"acc_title_value\"; }\naccDescr\\s*\":\"\\s* { this.begin(\"acc_descr\");return 'acc_descr'; }\n<acc_descr>(?!\\n|;|#)*[^\\n]* { this.popState(); return \"acc_descr_value\"; }\naccDescr\\s*\"{\"\\s* { this.begin(\"acc_descr_multiline\");}\n<acc_descr_multiline>[\\}] { this.popState(); }\n<acc_descr_multiline>[^\\}]* return \"acc_descr_multiline_value\";\n(\\r?\\n)+ return 'NEWLINE';\n\\s+ /* skip all whitespace */\n\\#[^\\n]* /* skip comments */\n\\%%[^\\n]* /* skip comments */\n<<EOF>> return 'EOF';\n\n\"requirementDiagram\" return 'RD';\n\n\"{\" return 'STRUCT_START';\n\"}\" return 'STRUCT_STOP';\n\":\" return 'COLONSEP';\n\n\"id\" return 'ID';\n\"text\" return 'TEXT';\n\"risk\" return 'RISK';\n\"verifyMethod\" return 'VERIFYMTHD';\n\n\"requirement\" return 'REQUIREMENT';\n\"functionalRequirement\" return 'FUNCTIONAL_REQUIREMENT';\n\"interfaceRequirement\" return 'INTERFACE_REQUIREMENT';\n\"performanceRequirement\" return 'PERFORMANCE_REQUIREMENT';\n\"physicalRequirement\" return 'PHYSICAL_REQUIREMENT';\n\"designConstraint\" return 'DESIGN_CONSTRAINT';\n\n\"low\" return 'LOW_RISK';\n\"medium\" return 'MED_RISK';\n\"high\" return 'HIGH_RISK';\n\n\"analysis\" return 'VERIFY_ANALYSIS';\n\"demonstration\" return 'VERIFY_DEMONSTRATION';\n\"inspection\" return 'VERIFY_INSPECTION';\n\"test\" return 'VERIFY_TEST';\n\n\"element\" return 'ELEMENT';\n\n\"contains\" return 'CONTAINS';\n\"copies\" return 'COPIES';\n\"derives\" return 'DERIVES';\n\"satisfies\" return 'SATISFIES';\n\"verifies\" return 'VERIFIES';\n\"refines\" return 'REFINES';\n\"traces\" return 'TRACES';\n\n\"type\" return 'TYPE';\n\"docref\" return 'DOCREF';\n\n\"<-\" return 'END_ARROW_L';\n\"->\" {return 'END_ARROW_R';}\n\"-\" {return 'LINE';}\n\n[\"] { this.begin(\"string\"); }\n<string>[\"] { this.popState(); }\n<string>[^\"]* { return \"qString\"; }\n\n[\\w][^\\r\\n\\{\\<\\>\\-\\=]* { yytext = yytext.trim(); return 'unqString';}\n\n/lex\n\n%start start\n\n%% /* language grammar */\n\nstart\n : directive NEWLINE start\n | directive start\n | RD NEWLINE diagram EOF;\n\ndirective\n : openDirective typeDirective closeDirective\n | openDirective typeDirective ':' argDirective closeDirective\n | acc_title acc_title_value { $$=$2.trim();yy.setAccTitle($$); }\n | acc_descr acc_descr_value { $$=$2.trim();yy.setAccDescription($$); }\n | acc_descr_multiline_value { $$=$1.trim();yy.setAccDescription($$); }\n ;\nopenDirective\n : open_directive { yy.parseDirective('%%{', 'open_directive'); };\n\ntypeDirective\n : type_directive { yy.parseDirective($1, 'type_directive'); };\n\nargDirective\n : arg_directive { $1 = $1.trim().replace(/'/g, '\"'); yy.parseDirective($1, 'arg_directive'); };\n\ncloseDirective\n : close_directive { yy.parseDirective('}%%', 'close_directive', 'pie'); };\n\ndiagram\n : /* empty */ { $$ = [] }\n | requirementDef diagram\n | elementDef diagram\n | relationshipDef diagram\n | directive diagram\n | NEWLINE diagram;\n\nrequirementDef\n : requirementType requirementName STRUCT_START NEWLINE requirementBody\n { yy.addRequirement($2, $1) };\n\nrequirementBody\n : ID COLONSEP id NEWLINE requirementBody\n { yy.setNewReqId($3); }\n | TEXT COLONSEP text NEWLINE requirementBody\n { yy.setNewReqText($3); }\n | RISK COLONSEP riskLevel NEWLINE requirementBody\n { yy.setNewReqRisk($3); }\n | VERIFYMTHD COLONSEP verifyType NEWLINE requirementBody\n { yy.setNewReqVerifyMethod($3); }\n | NEWLINE requirementBody\n | STRUCT_STOP;\n\nrequirementType\n : REQUIREMENT\n { $$=yy.RequirementType.REQUIREMENT;}\n | FUNCTIONAL_REQUIREMENT\n { $$=yy.RequirementType.FUNCTIONAL_REQUIREMENT;}\n | INTERFACE_REQUIREMENT\n { $$=yy.RequirementType.INTERFACE_REQUIREMENT;}\n | PERFORMANCE_REQUIREMENT\n { $$=yy.RequirementType.PERFORMANCE_REQUIREMENT;}\n | PHYSICAL_REQUIREMENT\n { $$=yy.RequirementType.PHYSICAL_REQUIREMENT;}\n | DESIGN_CONSTRAINT\n { $$=yy.RequirementType.DESIGN_CONSTRAINT;};\n\nriskLevel\n : LOW_RISK { $$=yy.RiskLevel.LOW_RISK;}\n | MED_RISK { $$=yy.RiskLevel.MED_RISK;}\n | HIGH_RISK { $$=yy.RiskLevel.HIGH_RISK;};\n\nverifyType\n : VERIFY_ANALYSIS\n { $$=yy.VerifyType.VERIFY_ANALYSIS;}\n | VERIFY_DEMONSTRATION\n { $$=yy.VerifyType.VERIFY_DEMONSTRATION;}\n | VERIFY_INSPECTION\n { $$=yy.VerifyType.VERIFY_INSPECTION;}\n | VERIFY_TEST\n { $$=yy.VerifyType.VERIFY_TEST;};\n\nelementDef\n : ELEMENT elementName STRUCT_START NEWLINE elementBody\n { yy.addElement($2) };\n\nelementBody\n : TYPE COLONSEP type NEWLINE elementBody\n { yy.setNewElementType($3); }\n | DOCREF COLONSEP ref NEWLINE elementBody\n { yy.setNewElementDocRef($3); }\n | NEWLINE elementBody\n | STRUCT_STOP;\n\nrelationshipDef\n : id END_ARROW_L relationship LINE id\n { yy.addRelationship($3, $5, $1) }\n | id LINE relationship END_ARROW_R id\n { yy.addRelationship($3, $1, $5) };\n\nrelationship\n : CONTAINS\n { $$=yy.Relationships.CONTAINS;}\n | COPIES\n { $$=yy.Relationships.COPIES;}\n | DERIVES\n { $$=yy.Relationships.DERIVES;}\n | SATISFIES\n { $$=yy.Relationships.SATISFIES;}\n | VERIFIES\n { $$=yy.Relationships.VERIFIES;}\n | REFINES\n { $$=yy.Relationships.REFINES;}\n | TRACES\n { $$=yy.Relationships.TRACES;};\n\n\nrequirementName: unqString | qString;\nid : unqString | qString;\ntext : unqString | qString;\nelementName : unqString | qString;\ntype : unqString | qString;\nref : unqString | qString;\n\n%%\n","import * as configApi from '../../config';\nimport { log } from '../../logger';\nimport mermaidAPI from '../../mermaidAPI';\n\nimport {\n setAccTitle,\n getAccTitle,\n getAccDescription,\n setAccDescription,\n clear as commonClear,\n} from '../../commonDb';\n\nlet relations = [];\nlet latestRequirement = {};\nlet requirements = {};\nlet latestElement = {};\nlet elements = {};\n\nconst RequirementType = {\n REQUIREMENT: 'Requirement',\n FUNCTIONAL_REQUIREMENT: 'Functional Requirement',\n INTERFACE_REQUIREMENT: 'Interface Requirement',\n PERFORMANCE_REQUIREMENT: 'Performance Requirement',\n PHYSICAL_REQUIREMENT: 'Physical Requirement',\n DESIGN_CONSTRAINT: 'Design Constraint',\n};\n\nconst RiskLevel = {\n LOW_RISK: 'Low',\n MED_RISK: 'Medium',\n HIGH_RISK: 'High',\n};\n\nconst VerifyType = {\n VERIFY_ANALYSIS: 'Analysis',\n VERIFY_DEMONSTRATION: 'Demonstration',\n VERIFY_INSPECTION: 'Inspection',\n VERIFY_TEST: 'Test',\n};\n\nconst Relationships = {\n CONTAINS: 'contains',\n COPIES: 'copies',\n DERIVES: 'derives',\n SATISFIES: 'satisfies',\n VERIFIES: 'verifies',\n REFINES: 'refines',\n TRACES: 'traces',\n};\n\nexport const parseDirective = function (statement, context, type) {\n mermaidAPI.parseDirective(this, statement, context, type);\n};\n\nconst addRequirement = (name, type) => {\n if (requirements[name] === undefined) {\n requirements[name] = {\n name,\n type,\n\n id: latestRequirement.id,\n text: latestRequirement.text,\n risk: latestRequirement.risk,\n verifyMethod: latestRequirement.verifyMethod,\n };\n }\n latestRequirement = {};\n\n return requirements[name];\n};\n\nconst getRequirements = () => requirements;\n\nconst setNewReqId = (id) => {\n if (latestRequirement !== undefined) {\n latestRequirement.id = id;\n }\n};\n\nconst setNewReqText = (text) => {\n if (latestRequirement !== undefined) {\n latestRequirement.text = text;\n }\n};\n\nconst setNewReqRisk = (risk) => {\n if (latestRequirement !== undefined) {\n latestRequirement.risk = risk;\n }\n};\n\nconst setNewReqVerifyMethod = (verifyMethod) => {\n if (latestRequirement !== undefined) {\n latestRequirement.verifyMethod = verifyMethod;\n }\n};\n\nconst addElement = (name) => {\n if (elements[name] === undefined) {\n elements[name] = {\n name,\n\n type: latestElement.type,\n docRef: latestElement.docRef,\n };\n log.info('Added new requirement: ', name);\n }\n latestElement = {};\n\n return elements[name];\n};\n\nconst getElements = () => elements;\n\nconst setNewElementType = (type) => {\n if (latestElement !== undefined) {\n latestElement.type = type;\n }\n};\n\nconst setNewElementDocRef = (docRef) => {\n if (latestElement !== undefined) {\n latestElement.docRef = docRef;\n }\n};\n\nconst addRelationship = (type, src, dst) => {\n relations.push({\n type,\n src,\n dst,\n });\n};\n\nconst getRelationships = () => relations;\n\nconst clear = () => {\n relations = [];\n latestRequirement = {};\n requirements = {};\n latestElement = {};\n elements = {};\n commonClear();\n};\n\nexport default {\n RequirementType,\n RiskLevel,\n VerifyType,\n Relationships,\n\n parseDirective,\n getConfig: () => configApi.getConfig().req,\n\n addRequirement,\n getRequirements,\n setNewReqId,\n setNewReqText,\n setNewReqRisk,\n setNewReqVerifyMethod,\n setAccTitle,\n getAccTitle,\n setAccDescription,\n getAccDescription,\n\n addElement,\n getElements,\n setNewElementType,\n setNewElementDocRef,\n\n addRelationship,\n getRelationships,\n\n clear,\n};\n","const getStyles = (options) => `\n\n marker {\n fill: ${options.relationColor};\n stroke: ${options.relationColor};\n }\n\n marker.cross {\n stroke: ${options.lineColor};\n }\n\n svg {\n font-family: ${options.fontFamily};\n font-size: ${options.fontSize};\n }\n\n .reqBox {\n fill: ${options.requirementBackground};\n fill-opacity: 100%;\n stroke: ${options.requirementBorderColor};\n stroke-width: ${options.requirementBorderSize};\n }\n \n .reqTitle, .reqLabel{\n fill: ${options.requirementTextColor};\n }\n .reqLabelBox {\n fill: ${options.relationLabelBackground};\n fill-opacity: 100%;\n }\n\n .req-title-line {\n stroke: ${options.requirementBorderColor};\n stroke-width: ${options.requirementBorderSize};\n }\n .relationshipLine {\n stroke: ${options.relationColor};\n stroke-width: 1;\n }\n .relationshipLabel {\n fill: ${options.relationLabelColor};\n }\n\n`;\n// fill', conf.rect_fill)\nexport default getStyles;\n","const ReqMarkers = {\n CONTAINS: 'contains',\n ARROW: 'arrow',\n};\n\nconst insertLineEndings = (parentNode, conf) => {\n let containsNode = parentNode\n .append('defs')\n .append('marker')\n .attr('id', ReqMarkers.CONTAINS + '_line_ending')\n .attr('refX', 0)\n .attr('refY', conf.line_height / 2)\n .attr('markerWidth', conf.line_height)\n .attr('markerHeight', conf.line_height)\n .attr('orient', 'auto')\n .append('g');\n\n containsNode\n .append('circle')\n .attr('cx', conf.line_height / 2)\n .attr('cy', conf.line_height / 2)\n .attr('r', conf.line_height / 2)\n // .attr('stroke', conf.rect_border_color)\n // .attr('stroke-width', 1)\n .attr('fill', 'none');\n\n containsNode\n .append('line')\n .attr('x1', 0)\n .attr('x2', conf.line_height)\n .attr('y1', conf.line_height / 2)\n .attr('y2', conf.line_height / 2)\n // .attr('stroke', conf.rect_border_color)\n .attr('stroke-width', 1);\n\n containsNode\n .append('line')\n .attr('y1', 0)\n .attr('y2', conf.line_height)\n .attr('x1', conf.line_height / 2)\n .attr('x2', conf.line_height / 2)\n // .attr('stroke', conf.rect_border_color)\n .attr('stroke-width', 1);\n\n parentNode\n .append('defs')\n .append('marker')\n .attr('id', ReqMarkers.ARROW + '_line_ending')\n .attr('refX', conf.line_height)\n .attr('refY', 0.5 * conf.line_height)\n .attr('markerWidth', conf.line_height)\n .attr('markerHeight', conf.line_height)\n .attr('orient', 'auto')\n .append('path')\n .attr(\n 'd',\n `M0,0\n L${conf.line_height},${conf.line_height / 2}\n M${conf.line_height},${conf.line_height / 2}\n L0,${conf.line_height}`\n )\n .attr('stroke-width', 1);\n // .attr('stroke', conf.rect_border_color);\n};\n\nexport default {\n ReqMarkers,\n insertLineEndings,\n};\n","import { line, select } from 'd3';\nimport { layout as dagreLayout } from 'dagre-d3-es/src/dagre/index.js';\nimport * as graphlib from 'dagre-d3-es/src/graphlib/index.js';\nimport { log } from '../../logger';\nimport { configureSvgSize } from '../../setupGraphViewbox';\nimport common from '../common/common';\nimport markers from './requirementMarkers';\nimport { getConfig } from '../../config';\n\nlet conf = {};\nlet relCnt = 0;\n\nconst newRectNode = (parentNode, id) => {\n return parentNode\n .insert('rect', '#' + id)\n .attr('class', 'req reqBox')\n .attr('x', 0)\n .attr('y', 0)\n .attr('width', conf.rect_min_width + 'px')\n .attr('height', conf.rect_min_height + 'px');\n};\n\nconst newTitleNode = (parentNode, id, txts) => {\n let x = conf.rect_min_width / 2;\n\n let title = parentNode\n .append('text')\n .attr('class', 'req reqLabel reqTitle')\n .attr('id', id)\n .attr('x', x)\n .attr('y', conf.rect_padding)\n .attr('dominant-baseline', 'hanging');\n // .attr(\n // 'style',\n // 'font-family: ' + configApi.getConfig().fontFamily + '; font-size: ' + conf.fontSize + 'px'\n // )\n let i = 0;\n txts.forEach((textStr) => {\n if (i == 0) {\n title\n .append('tspan')\n .attr('text-anchor', 'middle')\n .attr('x', conf.rect_min_width / 2)\n .attr('dy', 0)\n .text(textStr);\n } else {\n title\n .append('tspan')\n .attr('text-anchor', 'middle')\n .attr('x', conf.rect_min_width / 2)\n .attr('dy', conf.line_height * 0.75)\n .text(textStr);\n }\n i++;\n });\n\n let yPadding = 1.5 * conf.rect_padding;\n let linePadding = i * conf.line_height * 0.75;\n let totalY = yPadding + linePadding;\n\n parentNode\n .append('line')\n .attr('class', 'req-title-line')\n .attr('x1', '0')\n .attr('x2', conf.rect_min_width)\n .attr('y1', totalY)\n .attr('y2', totalY);\n\n return {\n titleNode: title,\n y: totalY,\n };\n};\n\nconst newBodyNode = (parentNode, id, txts, yStart) => {\n let body = parentNode\n .append('text')\n .attr('class', 'req reqLabel')\n .attr('id', id)\n .attr('x', conf.rect_padding)\n .attr('y', yStart)\n .attr('dominant-baseline', 'hanging');\n // .attr(\n // 'style',\n // 'font-family: ' + configApi.getConfig().fontFamily + '; font-size: ' + conf.fontSize + 'px'\n // );\n\n let currentRow = 0;\n const charLimit = 30;\n let wrappedTxts = [];\n txts.forEach((textStr) => {\n let currentTextLen = textStr.length;\n while (currentTextLen > charLimit && currentRow < 3) {\n let firstPart = textStr.substring(0, charLimit);\n textStr = textStr.substring(charLimit, textStr.length);\n currentTextLen = textStr.length;\n wrappedTxts[wrappedTxts.length] = firstPart;\n currentRow++;\n }\n if (currentRow == 3) {\n let lastStr = wrappedTxts[wrappedTxts.length - 1];\n wrappedTxts[wrappedTxts.length - 1] = lastStr.substring(0, lastStr.length - 4) + '...';\n } else {\n wrappedTxts[wrappedTxts.length] = textStr;\n }\n currentRow = 0;\n });\n\n wrappedTxts.forEach((textStr) => {\n body.append('tspan').attr('x', conf.rect_padding).attr('dy', conf.line_height).text(textStr);\n });\n\n return body;\n};\n\nconst addEdgeLabel = (parentNode, svgPath, conf, txt) => {\n // Find the half-way point\n const len = svgPath.node().getTotalLength();\n const labelPoint = svgPath.node().getPointAtLength(len * 0.5);\n\n // Append a text node containing the label\n const labelId = 'rel' + relCnt;\n relCnt++;\n\n const labelNode = parentNode\n .append('text')\n .attr('class', 'req relationshipLabel')\n .attr('id', labelId)\n .attr('x', labelPoint.x)\n .attr('y', labelPoint.y)\n .attr('text-anchor', 'middle')\n .attr('dominant-baseline', 'middle')\n // .attr('style', 'font-family: ' + conf.fontFamily + '; font-size: ' + conf.fontSize + 'px')\n .text(txt);\n\n // Figure out how big the opaque 'container' rectangle needs to be\n const labelBBox = labelNode.node().getBBox();\n\n // Insert the opaque rectangle before the text label\n parentNode\n .insert('rect', '#' + labelId)\n .attr('class', 'req reqLabelBox')\n .attr('x', labelPoint.x - labelBBox.width / 2)\n .attr('y', labelPoint.y - labelBBox.height / 2)\n .attr('width', labelBBox.width)\n .attr('height', labelBBox.height)\n .attr('fill', 'white')\n .attr('fill-opacity', '85%');\n};\n\nconst drawRelationshipFromLayout = function (svg, rel, g, insert, diagObj) {\n // Find the edge relating to this relationship\n const edge = g.edge(elementString(rel.src), elementString(rel.dst));\n\n // Get a function that will generate the line path\n const lineFunction = line()\n .x(function (d) {\n return d.x;\n })\n .y(function (d) {\n return d.y;\n });\n\n // Insert the line at the right place\n const svgPath = svg\n .insert('path', '#' + insert)\n .attr('class', 'er relationshipLine')\n .attr('d', lineFunction(edge.points))\n .attr('fill', 'none');\n\n if (rel.type == diagObj.db.Relationships.CONTAINS) {\n svgPath.attr(\n 'marker-start',\n 'url(' + common.getUrl(conf.arrowMarkerAbsolute) + '#' + rel.type + '_line_ending' + ')'\n );\n } else {\n svgPath.attr('stroke-dasharray', '10,7');\n svgPath.attr(\n 'marker-end',\n 'url(' +\n common.getUrl(conf.arrowMarkerAbsolute) +\n '#' +\n markers.ReqMarkers.ARROW +\n '_line_ending' +\n ')'\n );\n }\n\n addEdgeLabel(svg, svgPath, conf, `<<${rel.type}>>`);\n\n return;\n};\n\nexport const drawReqs = (reqs, graph, svgNode) => {\n Object.keys(reqs).forEach((reqName) => {\n let req = reqs[reqName];\n reqName = elementString(reqName);\n log.info('Added new requirement: ', reqName);\n\n const groupNode = svgNode.append('g').attr('id', reqName);\n const textId = 'req-' + reqName;\n const rectNode = newRectNode(groupNode, textId);\n\n let nodes = [];\n\n let titleNodeInfo = newTitleNode(groupNode, reqName + '_title', [\n `<<${req.type}>>`,\n `${req.name}`,\n ]);\n\n nodes.push(titleNodeInfo.titleNode);\n\n let bodyNode = newBodyNode(\n groupNode,\n reqName + '_body',\n [\n `Id: ${req.id}`,\n `Text: ${req.text}`,\n `Risk: ${req.risk}`,\n `Verification: ${req.verifyMethod}`,\n ],\n titleNodeInfo.y\n );\n\n nodes.push(bodyNode);\n\n const rectBBox = rectNode.node().getBBox();\n\n // Add the entity to the graph\n graph.setNode(reqName, {\n width: rectBBox.width,\n height: rectBBox.height,\n shape: 'rect',\n id: reqName,\n });\n });\n};\n\nexport const drawElements = (els, graph, svgNode) => {\n Object.keys(els).forEach((elName) => {\n let el = els[elName];\n const id = elementString(elName);\n\n const groupNode = svgNode.append('g').attr('id', id);\n const textId = 'element-' + id;\n const rectNode = newRectNode(groupNode, textId);\n\n let nodes = [];\n\n let titleNodeInfo = newTitleNode(groupNode, textId + '_title', [`<<Element>>`, `${elName}`]);\n\n nodes.push(titleNodeInfo.titleNode);\n\n let bodyNode = newBodyNode(\n groupNode,\n textId + '_body',\n [`Type: ${el.type || 'Not Specified'}`, `Doc Ref: ${el.docRef || 'None'}`],\n titleNodeInfo.y\n );\n\n nodes.push(bodyNode);\n\n const rectBBox = rectNode.node().getBBox();\n\n // Add the entity to the graph\n graph.setNode(id, {\n width: rectBBox.width,\n height: rectBBox.height,\n shape: 'rect',\n id: id,\n });\n });\n};\n\nconst addRelationships = (relationships, g) => {\n relationships.forEach(function (r) {\n let src = elementString(r.src);\n let dst = elementString(r.dst);\n g.setEdge(src, dst, { relationship: r });\n });\n return relationships;\n};\n\nconst adjustEntities = function (svgNode, graph) {\n graph.nodes().forEach(function (v) {\n if (v !== undefined && graph.node(v) !== undefined) {\n svgNode.select('#' + v);\n svgNode\n .select('#' + v)\n .attr(\n 'transform',\n 'translate(' +\n (graph.node(v).x - graph.node(v).width / 2) +\n ',' +\n (graph.node(v).y - graph.node(v).height / 2) +\n ' )'\n );\n }\n });\n return;\n};\n\nconst elementString = (str) => {\n return str.replace(/\\s/g, '').replace(/\\./g, '_');\n};\n\nexport const draw = (text, id, _version, diagObj) => {\n conf = getConfig().requirement;\n diagObj.db.clear();\n diagObj.parser.parse(text);\n\n const securityLevel = conf.securityLevel;\n // Handle root and Document for when rendering in sandbox mode\n let sandboxElement;\n if (securityLevel === 'sandbox') {\n sandboxElement = select('#i' + id);\n }\n const root =\n securityLevel === 'sandbox'\n ? select(sandboxElement.nodes()[0].contentDocument.body)\n : select('body');\n\n const svg = root.select(`[id='${id}']`);\n markers.insertLineEndings(svg, conf);\n\n const g = new graphlib.Graph({\n multigraph: false,\n compound: false,\n directed: true,\n })\n .setGraph({\n rankdir: conf.layoutDirection,\n marginx: 20,\n marginy: 20,\n nodesep: 100,\n edgesep: 100,\n ranksep: 100,\n })\n .setDefaultEdgeLabel(function () {\n return {};\n });\n\n let requirements = diagObj.db.getRequirements();\n let elements = diagObj.db.getElements();\n let relationships = diagObj.db.getRelationships();\n\n drawReqs(requirements, g, svg);\n drawElements(elements, g, svg);\n addRelationships(relationships, g);\n dagreLayout(g);\n adjustEntities(svg, g);\n\n relationships.forEach(function (rel) {\n drawRelationshipFromLayout(svg, rel, g, id, diagObj);\n });\n\n const padding = conf.rect_padding;\n const svgBounds = svg.node().getBBox();\n const width = svgBounds.width + padding * 2;\n const height = svgBounds.height + padding * 2;\n\n configureSvgSize(svg, height, width, conf.useMaxWidth);\n\n svg.attr('viewBox', `${svgBounds.x - padding} ${svgBounds.y - padding} ${width} ${height}`);\n};\n\nexport default {\n draw,\n};\n","import { DiagramDefinition } from '../../diagram-api/types';\n// @ts-ignore: TODO Fix ts errors\nimport parser from './parser/requirementDiagram';\nimport db from './requirementDb';\nimport styles from './styles';\nimport renderer from './requirementRenderer';\n\nexport const diagram: DiagramDefinition = {\n parser,\n db,\n renderer,\n styles,\n};\n"],"names":["parser","o","k","v","$V0","$V1","$V2","$V3","$V4","$V5","$V6","$V7","$V8","$V9","$Va","$Vb","$Vc","$Vd","$Ve","$Vf","$Vg","$Vh","$Vi","$Vj","$Vk","$Vl","$Vm","$Vn","$Vo","$Vp","$Vq","$Vr","$Vs","$Vt","$Vu","$Vv","$Vw","$Vx","$Vy","$Vz","$VA","$VB","$VC","yytext","yyleng","yylineno","yy","yystate","$$","_$","$0","str","hash","error","input","self","stack","tstack","vstack","lstack","table","TERROR","EOF","args","lexer","sharedState","yyloc","ranges","lex","token","symbol","state","action","r","yyval","p","len","newState","expected","errStr","ch","lines","oldLines","n","past","next","pre","c","match","indexed_rule","backup","tempMatch","index","rules","i","condition","yy_","$avoiding_name_collisions","YY_START","Parser","relations","latestRequirement","requirements","latestElement","elements","RequirementType","RiskLevel","VerifyType","Relationships","parseDirective","statement","context","type","mermaidAPI","addRequirement","name","getRequirements","setNewReqId","id","setNewReqText","text","setNewReqRisk","risk","setNewReqVerifyMethod","verifyMethod","addElement","log","getElements","setNewElementType","setNewElementDocRef","docRef","addRelationship","src","dst","getRelationships","clear","commonClear","db","configApi.getConfig","setAccTitle","getAccTitle","setAccDescription","getAccDescription","getStyles","options","styles","ReqMarkers","insertLineEndings","parentNode","conf","containsNode","markers","relCnt","newRectNode","newTitleNode","txts","x","title","textStr","yPadding","linePadding","totalY","newBodyNode","yStart","body","currentRow","charLimit","wrappedTxts","currentTextLen","firstPart","lastStr","addEdgeLabel","svgPath","txt","labelPoint","labelId","labelBBox","drawRelationshipFromLayout","svg","rel","g","insert","diagObj","edge","elementString","lineFunction","line","d","common","drawReqs","reqs","graph","svgNode","reqName","req","groupNode","textId","rectNode","titleNodeInfo","rectBBox","drawElements","els","elName","el","addRelationships","relationships","adjustEntities","draw","_version","getConfig","securityLevel","sandboxElement","select","graphlib.Graph","dagreLayout","padding","svgBounds","width","height","configureSvgSize","renderer","diagram"],"mappings":";;;;;;;;;;AAyEA,IAAIA,KAAU,WAAU;AACxB,MAAIC,IAAE,SAASC,GAAEC,GAAEF,GAAE,GAAE;AAAC,SAAIA,IAAEA,KAAG,CAAA,GAAG,IAAEC,EAAE,QAAO,KAAID,EAAEC,EAAE,CAAC,CAAC,IAAEC;AAAE;AAAC,WAAOF;AAAA,EAAC,GAAEG,IAAI,CAAC,GAAE,CAAC,GAAEC,IAAI,CAAC,GAAE,CAAC,GAAEC,IAAI,CAAC,GAAE,CAAC,GAAEC,IAAI,CAAC,GAAE,CAAC,GAAEC,IAAI,CAAC,GAAE,CAAC,GAAEC,IAAI,CAAC,GAAE,GAAE,GAAE,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,EAAE,GAAEC,IAAI,CAAC,GAAE,EAAE,GAAEC,IAAI,CAAC,GAAE,EAAE,GAAEC,IAAI,CAAC,GAAE,EAAE,GAAEC,IAAI,CAAC,GAAE,EAAE,GAAEC,IAAI,CAAC,GAAE,EAAE,GAAEC,IAAI,CAAC,GAAE,EAAE,GAAEC,IAAI,CAAC,GAAE,EAAE,GAAEC,IAAI,CAAC,GAAE,EAAE,GAAEC,IAAI,CAAC,GAAE,EAAE,GAAEC,IAAI,CAAC,GAAE,EAAE,GAAEC,IAAI,CAAC,GAAE,EAAE,GAAEC,KAAI,CAAC,GAAE,EAAE,GAAEC,IAAI,CAAC,IAAG,EAAE,GAAEC,KAAI,CAAC,GAAE,GAAE,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,IAAG,EAAE,GAAEC,KAAI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