Skip to content

Commit

Permalink
feat: hide dev Tools button in Prod mode
Browse files Browse the repository at this point in the history
  • Loading branch information
domiSchenk committed Aug 28, 2021
1 parent 1dfd9e2 commit 68764dd
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src-tauri/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/app/routes/settings/settings.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
<div cds-layout="horizontal gap:sm">
<cds-button (click)="save()" [loadingState]="saveState" [disabled]="form.invalid || !form.dirty">Save
</cds-button>
<cds-button status="success" (click)="openDevTools()">Open DevTools</cds-button>
<cds-button status="success" (click)="openDevTools()" *ngIf="devMode">Open DevTools</cds-button>
</div>
</form>

Expand Down
2 changes: 2 additions & 0 deletions src/app/routes/settings/settings.component.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import { environment } from '@env/environment';

import { Component, Inject, OnInit, Renderer2, ViewChild } from '@angular/core';
import { ErrorService, StoreService } from '@core/services';
Expand All @@ -15,6 +16,7 @@ import { selectFolder } from '@shared/functions';
export class SettingsComponent implements OnInit {

@ViewChild('form') settingsForm: NgForm;
devMode = !environment.production;

gridCounts = [25, 50, 100];
gridCount: number;
Expand Down

0 comments on commit 68764dd

Please sign in to comment.