MCPcopy Create free account
hub / github.com/SplootCode/splootcode / getLeftCapShape

Function getLeftCapShape

packages/editor/src/components/string_node.tsx:17–30  ·  view source on GitHub ↗
(className: string, x: number, y: number, height: number)

Source from the content-addressed store, hash-verified

15}
16
17export function getLeftCapShape(className: string, x: number, y: number, height: number) {
18 return (
19 <>
20 <path
21 tabIndex={0}
22 className={className}
23 d={`M ${x + 4} ${y} q -4,0 -4,4 v ${height - 8} q 0,4 4,4 h ${STRING_CAP_WIDTH - 7} v ${-height} z`}
24 />
25 <g transform={`translate(${x} ${y + 14})`}>
26 <text className="string-node-cap-text">&apos;</text>
27 </g>
28 </>
29 )
30}
31
32function getRightCapShape(className: string, x: number, y: number, height: number) {
33 return (

Callers 1

renderMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected