Skip to content

Commit

Permalink
closes #71
Browse files Browse the repository at this point in the history
  • Loading branch information
seiyria committed Aug 22, 2024
1 parent 134917f commit ddafe71
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/app/helpers/core.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import { id } from './id';
export const defaultCore: () => ICoreContent = () => ({
_id: id(),
name: '',
desc: '',
yaml: '',
json: undefined,
});
5 changes: 5 additions & 0 deletions src/app/tabs/cores/cores-editor/cores-editor.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,11 @@
(ngModelChange)="update('name', $event)" [class.has-error]="!satisfiesUnique()" />
</div>

<div class="form-row">
<app-input-floating-label>Description</app-input-floating-label>
<input [(ngModel)]="editingData.desc" type="text" placeholder="Enter description..." class="form-input" />
</div>

<div class="form-row">
<ngs-code-editor class="editor-container" [theme]="'vs-dark'" [codeModel]="fileModel"
[options]="{ contextmenu: true }" (valueChanged)="onYamlChanged($event)"></ngs-code-editor>
Expand Down
8 changes: 8 additions & 0 deletions src/app/tabs/cores/cores.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,14 @@ export class CoresComponent extends EditorBaseTableComponent<EditingType> {
filter: 'agTextColumnFilter',
sort: 'asc',
},
{
field: 'desc',
flex: 5,
cellDataType: 'text',
filter: 'agTextColumnFilter',
cellClass: 'leading-4 whitespace-break-spaces',
sortable: false,
},
{
field: '',
width: 200,
Expand Down
1 change: 1 addition & 0 deletions src/interfaces/core.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { HasIdentification } from './identified';

export interface ICoreContent extends HasIdentification {
name: string;
desc: string;
yaml: string;
json: any;
}

0 comments on commit ddafe71

Please sign in to comment.