Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 24 additions & 2 deletions Frontend/src/app/md2html/md2html.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,30 @@ <h2>Markdown to HTML Converter</h2>
<br />
</div>
<div class="col-md-6">
<label class="form-label">HTML:</label>
<div class="d-flex gap-2">
<label class="form-label">To:</label>
<div class="form-check ">
<input class="form-check-input" type="radio" name="toRadio" id="toPreview" value="preview"
[(ngModel)]="to" (change)="convert()">
<label class="form-check-label" for="toPreview">
Preview
</label>
</div>
<div class="form-check">
<input class="form-check-input" type="radio" name="toRadio" id="toHtml" value="html"
[(ngModel)]="to" (change)="convert()">
<label class="form-check-label" for="toHtml">
HTML
</label>
</div>
</div>
<div class="code-border" [@valueChangeAnim]="status">
@if(to==="html"){
<code-area innerStyle="min-height:500px;" [(code)]="htmlCode" language="markup" readonly="true" />
}
@else{
<div style="min-height:500px;" [innerHTML]="htmlCode"></div>
}
</div>
<br />
</div>
Expand Down Expand Up @@ -47,7 +68,8 @@ <h2>Markdown to HTML Converter</h2>
Markdown&#39;s syntax includes elements like <code>#</code> for headings, <code>*</code> for lists, and
<code>**</code> for bold text, making it intuitive and fast for creating readable, structured content.
Its popularity has grown widely, especially in documentation, blogging, and collaborative platforms like
GitHub, where simplicity and clarity are key.</p>
GitHub, where simplicity and clarity are key.
</p>
<p><strong>Conversion between HTML and Markdown</strong> is common because each serves distinct purposes in
different contexts. Converting Markdown to HTML is a straightforward way to take plain text content and
render it for the web, making it possible to publish articles, documentation, or blog posts without
Expand Down
1 change: 1 addition & 0 deletions Frontend/src/app/md2html/md2html.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ export class Md2htmlComponent implements AfterContentInit {
this is an example :p`;
protected htmlCode !: string;
protected status: boolean = false;
protected to: string = "preview";

protected inputDebouncer = new Subject<string>();

Expand Down