Skip to content

Commit

Permalink
Merge pull request #14 from schoero/development
Browse files Browse the repository at this point in the history
chore(release): v0.2.4
  • Loading branch information
schoero authored Nov 10, 2023
2 parents edfbcce + 3b4e32a commit 457cf0b
Show file tree
Hide file tree
Showing 5 changed files with 37 additions and 10 deletions.
23 changes: 23 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,28 @@
# Changelog

## v0.2.4

[compare changes](https://github.com/schoero/unwritten/compare/v0.2.2...v0.2.4)

### Fixes

- **renderer:html:** Section node title rendering ([236929f](https://github.com/schoero/unwritten/commit/236929f))
- Interpreting of circular types ([073f8ba](https://github.com/schoero/unwritten/commit/073f8ba))
- Render class name instead of `class` ([428d443](https://github.com/schoero/unwritten/commit/428d443))

### Refactors

- Preserve empty lines ([3e463ca](https://github.com/schoero/unwritten/commit/3e463ca))

### Chore

- **release:** V0.2.3 ([dcba3fd](https://github.com/schoero/unwritten/commit/dcba3fd))
- Remove unused types ([5a78055](https://github.com/schoero/unwritten/commit/5a78055))

### ❤️ Contributors

- Roger Schönbächler

## v0.2.3

[compare changes](https://github.com/schoero/unwritten/compare/v0.2.2...v0.2.3)
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "0.2.3",
"version": "0.2.4",
"type": "module",
"name": "unwritten",
"description": "unwritten is a cli tool that auto generates documentation from your JavaScript or TypeScript project by utilizing TSDoc or JSDoc comments.",
Expand Down
4 changes: 2 additions & 2 deletions src/renderer/markup/ast-converter/types/class.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@ scope("MarkupRenderer", TypeKind.Class, () => {
const convertedType = convertClassTypeInline(ctx, type as ClassType);
const renderedType = renderNode(ctx, convertedType);

it("should render the name of the type", () => {
expect(renderedType).toBe("class");
it("should render the name of the class", () => {
expect(renderedType).toBe("Class");
});

}
Expand Down
16 changes: 11 additions & 5 deletions src/renderer/markup/ast-converter/types/class.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import {
convertObjectTypeInline,
convertObjectTypeMultiline
} from "unwritten:renderer:markup/ast-converter/types/index";
import { encapsulate } from "unwritten:renderer/markup/utils/renderer.js";
import { getRenderConfig } from "unwritten:renderer/utils/config.js";
import { convertObjectTypeMultiline } from "unwritten:renderer:markup/ast-converter/types/index";

import type { ClassType } from "unwritten:interpreter:type-definitions/types";
import type { MarkupRenderContexts } from "unwritten:renderer:markup/types-definitions/markup";
Expand All @@ -12,7 +11,14 @@ import type {


export function convertClassTypeInline(ctx: MarkupRenderContexts, classType: ClassType): ConvertedClassTypeInline {
return convertObjectTypeInline(ctx, classType);

const renderConfig = getRenderConfig(ctx);

return encapsulate(
classType.name,
renderConfig.typeEncapsulation
);

}

export function convertClassTypeMultiline(ctx: MarkupRenderContexts, classType: ClassType): ConvertedClassTypeMultiline {
Expand Down
2 changes: 0 additions & 2 deletions src/renderer/markup/types-definitions/markup.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,7 @@ export interface MarkupRenderContext<CustomMarkupRenderer extends MarkupRenderer
memberContext: string[];
set nesting(value: number);
get nesting(): number;
_currentFile?: SourceFile;
_indentation?: number;
_links?: LinkRegistry;
_nesting?: number;
}

Expand Down

0 comments on commit 457cf0b

Please sign in to comment.