Skip to content

Commit

Permalink
b
Browse files Browse the repository at this point in the history
  • Loading branch information
polterguy committed Dec 20, 2023
1 parent 8fe962d commit b0cb52f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ import { SqlService } from 'src/app/services/sql.service';
*/
@Component({
selector: 'app-codemirror-formly',
template: `<ngx-codemirror #editor *ngIf="cmOptions" [options]="cmOptions" [(ngModel)]="model[field.key]"></ngx-codemirror>`,
template: `<ngx-codemirror #editor class="sql-formly-editor" *ngIf="cmOptions" [options]="cmOptions" [(ngModel)]="model[field.key]"></ngx-codemirror>`,
styleUrls: ['./codemirror-sql-formly.scss']
})
export class CodemirrorSqlFormlyComponent extends FieldType<FieldTypeConfig> implements OnInit {

Expand Down Expand Up @@ -106,12 +107,12 @@ export class CodemirrorSqlFormlyComponent extends FieldType<FieldTypeConfig> imp

next: (result: Databases) => {

this.databases = result;
this.generalService.hideLoading();
this.databases = result;
this.databaseChanged();
},

error: (error: any) => {
error: () => {

this.generalService.hideLoading();
this.generalService.showFeedback('Not a valid database-type/connection-string combination', 'errorMessage');
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@

::ng-deep .sql-formly-editor .CodeMirror {
max-height: 150px;
}

0 comments on commit b0cb52f

Please sign in to comment.