Skip to content

Commit 4427087

Browse files
authored
fix: Enable code tab by default (#16018) (CP: 24.0) (#16021)
1 parent 5160a7b commit 4427087

2 files changed

Lines changed: 2 additions & 10 deletions

File tree

vaadin-dev-server/src/main/java/com/vaadin/base/devserver/DebugWindowConnection.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@
4040
import com.vaadin.flow.server.startup.ApplicationConfiguration;
4141
import com.vaadin.pro.licensechecker.BuildType;
4242
import com.vaadin.pro.licensechecker.LicenseChecker;
43-
import com.vaadin.pro.licensechecker.LocalProKey;
4443
import com.vaadin.pro.licensechecker.Product;
4544

4645
import elemental.json.Json;
@@ -136,10 +135,6 @@ public void onConnect(AtmosphereResource resource) {
136135
.get(context).getFeatures().stream()
137136
.filter(feature -> !feature.equals(FeatureFlags.EXAMPLE))
138137
.collect(Collectors.toList())));
139-
140-
if (LocalProKey.get() != null) {
141-
send(resource, "vaadin-dev-tools-code-ok", null);
142-
}
143138
}
144139

145140
private void send(AtmosphereResource resource, String command,

vaadin-dev-server/src/main/resources/META-INF/frontend/vaadin-dev-tools/vaadin-dev-tools.ts

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -965,7 +965,8 @@ export class VaadinDevTools extends LitElement {
965965
private tabs: Tab[] = [
966966
{ id: 'log', title: 'Log', render: this.renderLog, activate: this.activateLog },
967967
{ id: 'info', title: 'Info', render: this.renderInfo },
968-
{ id: 'features', title: 'Feature Flags', render: this.renderFeatures }
968+
{ id: 'features', title: 'Feature Flags', render: this.renderFeatures },
969+
{ id: 'code', title: 'Code', render: this.renderCode }
969970
];
970971

971972
@state()
@@ -1056,10 +1057,6 @@ export class VaadinDevTools extends LitElement {
10561057
this.serverInfo = message.data as ServerInfo;
10571058
} else if (message?.command === 'featureFlags') {
10581059
this.features = message.data.features as Feature[];
1059-
} else if (message?.command === 'vaadin-dev-tools-code-ok') {
1060-
if ((window as any).Vaadin.Flow) {
1061-
this.tabs.push({ id: 'code', title: 'Code', render: this.renderCode });
1062-
}
10631060
} else {
10641061
// eslint-disable-next-line no-console
10651062
console.error('Unknown message from front-end connection:', JSON.stringify(message));

0 commit comments

Comments
 (0)