diff --git a/src/templates/Typedoc.jsx b/src/templates/Typedoc.jsx index 4b485b46..2937d9d5 100644 --- a/src/templates/Typedoc.jsx +++ b/src/templates/Typedoc.jsx @@ -162,7 +162,9 @@ const PropertyWrapper = ({ property, sourceUrl, parentAnchor }) => { if (deprecation) { deprecatedUse = deprecation.arguments.alternative.replace(/'/g, '') } + const sourceLink = `${sourceUrl}${fileName}#L${line}` + return (
{
)} - {fileName && ( - - source - - )} - {comment && (
{comment.text || comment.shortText} @@ -223,6 +214,17 @@ const PropertyWrapper = ({ property, sourceUrl, parentAnchor }) => { return } })()} + + {fileName && ( + + {`${fileName}#L${line}`} + + )}
) } diff --git a/src/templates/Typedoc.module.scss b/src/templates/Typedoc.module.scss index 72cedb22..0c52c5fa 100644 --- a/src/templates/Typedoc.module.scss +++ b/src/templates/Typedoc.module.scss @@ -91,13 +91,22 @@ } .sourceLink { - position: absolute; - bottom: $spacer / 2; - right: $spacer / 2; + display: block; font-size: $font-size-mini; - font-family: $font-family-button; - text-transform: uppercase; color: $brand-grey-light; + margin-top: $spacer / 2; + + &:hover, + &:focus { + transform: none; + } + + @media (min-width: $break-point--large) { + margin-top: 0; + position: absolute; + bottom: $spacer / 2; + right: $spacer / 2; + } } .deprecation {