Browse Source
- Add a public listing item-version endpoint to IotHubApiService
(GET /api/listings/public/by-slug/{slug}/item-version?ce=true&
tbVersion=N) returning MpItemVersionView, with the new
ListingItemVersionNotFound shape capturing the documented 404
bodies (noMatchingVersions / peRequired / minTbVersionRequired).
- Wire a tbVersionIntToString helper alongside the existing
tbVersionToInt so the dialogs can render the resolved versions
compactly (430 → "4.3", 421 → "4.2.1").
- Route /iot-hub/listing/:slug to TbIotHubItemResolverComponent.
Resolver picks the slug path first, dispatches the 404 bodies to
three handlers: noMatchingVersions reuses the existing
deep-link-not-found notification, peRequired opens a new dialog,
minTbVersionRequired opens another with the resolved min version.
- New TbIotHubPeRequiredDialogComponent renders the "Professional
Edition required" prompt and TbIotHubUpgradeRequiredDialogComponent
renders the "ThingsBoard upgrade required" prompt. Both reuse a
single upgrade-required.svg asset (Figma export) tinted via CSS
mask + background-color so the PE accent inherits without touching
the asset. The shared "Upgrade instance" button links to the right
upgrade doc per dialog.
- New TbIotHubAlarmRulesUnavailablePageComponent replaces
TbIotHubItemsPageComponent on /iot-hub/alarm-rules. It mirrors the
iot-hub-home glow-blob + dot-pattern background (alarm-rule
accent), renders the alarm-rules hero, a 28px title with the
primary "Thingsboard v4.3" span, the description, an Upgrade
instance link (https://thingsboard.io/docs/installation/upgrade-
instructions/), Back to IoT Hub, and the current platform version
read from env.tbVersion.
- Locale: pe-required-title / pe-required-message (bolded "Professional
Edition" / "Community Edition"), upgrade-required-title /
upgrade-required-message (bolded interpolations), and the alarm-
rules-unavailable-* keys for the new page.
pull/15772/head
17 changed files with 730 additions and 15 deletions
@ -0,0 +1,40 @@ |
|||||
|
<!-- |
||||
|
|
||||
|
Copyright © 2016-2026 The Thingsboard Authors |
||||
|
|
||||
|
Licensed under the Apache License, Version 2.0 (the "License"); |
||||
|
you may not use this file except in compliance with the License. |
||||
|
You may obtain a copy of the License at |
||||
|
|
||||
|
http://www.apache.org/licenses/LICENSE-2.0 |
||||
|
|
||||
|
Unless required by applicable law or agreed to in writing, software |
||||
|
distributed under the License is distributed on an "AS IS" BASIS, |
||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
||||
|
See the License for the specific language governing permissions and |
||||
|
limitations under the License. |
||||
|
|
||||
|
--> |
||||
|
<div class="tb-iot-hub-pe-required"> |
||||
|
<button mat-icon-button class="tb-iot-hub-pe-required-close" (click)="close()" tabindex="-1"> |
||||
|
<mat-icon>close</mat-icon> |
||||
|
</button> |
||||
|
|
||||
|
<span class="tb-iot-hub-pe-required-icon" aria-hidden="true"></span> |
||||
|
|
||||
|
<h2 class="tb-iot-hub-pe-required-title"> |
||||
|
{{ 'iot-hub.pe-required-title' | translate }} |
||||
|
</h2> |
||||
|
|
||||
|
<p class="tb-iot-hub-pe-required-message" |
||||
|
[innerHTML]="'iot-hub.pe-required-message' | translate"></p> |
||||
|
|
||||
|
<div class="tb-iot-hub-pe-required-actions"> |
||||
|
<button mat-button (click)="close()"> |
||||
|
{{ 'action.close' | translate }} |
||||
|
</button> |
||||
|
<button mat-flat-button color="primary" (click)="upgradeInstance()"> |
||||
|
{{ 'iot-hub.alarm-rules-unavailable-upgrade' | translate }} |
||||
|
</button> |
||||
|
</div> |
||||
|
</div> |
||||
@ -0,0 +1,77 @@ |
|||||
|
/** |
||||
|
* Copyright © 2016-2026 The Thingsboard Authors |
||||
|
* |
||||
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
||||
|
* you may not use this file except in compliance with the License. |
||||
|
* You may obtain a copy of the License at |
||||
|
* |
||||
|
* http://www.apache.org/licenses/LICENSE-2.0 |
||||
|
* |
||||
|
* Unless required by applicable law or agreed to in writing, software |
||||
|
* distributed under the License is distributed on an "AS IS" BASIS, |
||||
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
||||
|
* See the License for the specific language governing permissions and |
||||
|
* limitations under the License. |
||||
|
*/ |
||||
|
|
||||
|
@import "../../../../../scss/constants"; |
||||
|
|
||||
|
:host { |
||||
|
display: block; |
||||
|
width: 500px; |
||||
|
max-width: 100%; |
||||
|
} |
||||
|
|
||||
|
.tb-iot-hub-pe-required { |
||||
|
position: relative; |
||||
|
display: flex; |
||||
|
flex-direction: column; |
||||
|
align-items: center; |
||||
|
text-align: center; |
||||
|
gap: 20px; |
||||
|
padding: 40px; |
||||
|
background: white; |
||||
|
border-radius: 8px; |
||||
|
} |
||||
|
|
||||
|
.tb-iot-hub-pe-required-close { |
||||
|
position: absolute; |
||||
|
top: 8px; |
||||
|
right: 8px; |
||||
|
} |
||||
|
|
||||
|
// SVG illustration applied as a mask so the silhouette is filled |
||||
|
// with $tb-primary-color. PE builds inherit their own primary value |
||||
|
// without re-exporting the asset. |
||||
|
.tb-iot-hub-pe-required-icon { |
||||
|
display: block; |
||||
|
width: 100px; |
||||
|
height: 100px; |
||||
|
background-color: $tb-primary-color; |
||||
|
-webkit-mask: url('/assets/iot-hub/upgrade-required.svg') no-repeat center / contain; |
||||
|
mask: url('/assets/iot-hub/upgrade-required.svg') no-repeat center / contain; |
||||
|
} |
||||
|
|
||||
|
.tb-iot-hub-pe-required-title { |
||||
|
font-size: 24px; |
||||
|
font-weight: 500; |
||||
|
line-height: 32px; |
||||
|
letter-spacing: 0.15px; |
||||
|
color: rgba(0, 0, 0, 0.87); |
||||
|
margin: 0; |
||||
|
} |
||||
|
|
||||
|
.tb-iot-hub-pe-required-message { |
||||
|
font-size: 14px; |
||||
|
font-weight: 400; |
||||
|
line-height: 24px; |
||||
|
letter-spacing: 0.25px; |
||||
|
color: rgba(0, 0, 0, 0.76); |
||||
|
margin: 0; |
||||
|
} |
||||
|
|
||||
|
.tb-iot-hub-pe-required-actions { |
||||
|
display: flex; |
||||
|
align-items: center; |
||||
|
gap: 8px; |
||||
|
} |
||||
@ -0,0 +1,47 @@ |
|||||
|
///
|
||||
|
/// Copyright © 2016-2026 The Thingsboard Authors
|
||||
|
///
|
||||
|
/// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
|
/// you may not use this file except in compliance with the License.
|
||||
|
/// You may obtain a copy of the License at
|
||||
|
///
|
||||
|
/// http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
///
|
||||
|
/// Unless required by applicable law or agreed to in writing, software
|
||||
|
/// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
|
/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
|
/// See the License for the specific language governing permissions and
|
||||
|
/// limitations under the License.
|
||||
|
///
|
||||
|
|
||||
|
import { Component } from '@angular/core'; |
||||
|
import { MatDialogRef } from '@angular/material/dialog'; |
||||
|
import { Router } from '@angular/router'; |
||||
|
import { Store } from '@ngrx/store'; |
||||
|
import { AppState } from '@core/core.state'; |
||||
|
import { DialogComponent } from '@shared/components/dialog.component'; |
||||
|
|
||||
|
@Component({ |
||||
|
selector: 'tb-iot-hub-pe-required-dialog', |
||||
|
standalone: false, |
||||
|
templateUrl: './iot-hub-pe-required-dialog.component.html', |
||||
|
styleUrls: ['./iot-hub-pe-required-dialog.component.scss'] |
||||
|
}) |
||||
|
export class TbIotHubPeRequiredDialogComponent extends DialogComponent<TbIotHubPeRequiredDialogComponent> { |
||||
|
|
||||
|
constructor( |
||||
|
protected store: Store<AppState>, |
||||
|
protected router: Router, |
||||
|
protected dialogRef: MatDialogRef<TbIotHubPeRequiredDialogComponent> |
||||
|
) { |
||||
|
super(store, router, dialogRef); |
||||
|
} |
||||
|
|
||||
|
close(): void { |
||||
|
this.dialogRef.close(); |
||||
|
} |
||||
|
|
||||
|
upgradeInstance(): void { |
||||
|
window.open('https://thingsboard.io/docs/pe/installation/upgrade-from-ce/', '_blank'); |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,43 @@ |
|||||
|
<!-- |
||||
|
|
||||
|
Copyright © 2016-2026 The Thingsboard Authors |
||||
|
|
||||
|
Licensed under the Apache License, Version 2.0 (the "License"); |
||||
|
you may not use this file except in compliance with the License. |
||||
|
You may obtain a copy of the License at |
||||
|
|
||||
|
http://www.apache.org/licenses/LICENSE-2.0 |
||||
|
|
||||
|
Unless required by applicable law or agreed to in writing, software |
||||
|
distributed under the License is distributed on an "AS IS" BASIS, |
||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
||||
|
See the License for the specific language governing permissions and |
||||
|
limitations under the License. |
||||
|
|
||||
|
--> |
||||
|
<div class="tb-iot-hub-upgrade-required"> |
||||
|
<button mat-icon-button class="tb-iot-hub-upgrade-required-close" (click)="close()" tabindex="-1"> |
||||
|
<mat-icon>close</mat-icon> |
||||
|
</button> |
||||
|
|
||||
|
<span class="tb-iot-hub-upgrade-required-icon" aria-hidden="true"></span> |
||||
|
|
||||
|
<h2 class="tb-iot-hub-upgrade-required-title"> |
||||
|
{{ 'iot-hub.upgrade-required-title' | translate }} |
||||
|
</h2> |
||||
|
|
||||
|
<p class="tb-iot-hub-upgrade-required-message" |
||||
|
[innerHTML]="'iot-hub.upgrade-required-message' | translate:{ |
||||
|
minVersion: minVersion, |
||||
|
currentVersion: currentVersion |
||||
|
}"></p> |
||||
|
|
||||
|
<div class="tb-iot-hub-upgrade-required-actions"> |
||||
|
<button mat-button (click)="close()"> |
||||
|
{{ 'action.close' | translate }} |
||||
|
</button> |
||||
|
<button mat-flat-button color="primary" (click)="upgradeInstance()"> |
||||
|
{{ 'iot-hub.alarm-rules-unavailable-upgrade' | translate }} |
||||
|
</button> |
||||
|
</div> |
||||
|
</div> |
||||
@ -0,0 +1,76 @@ |
|||||
|
/** |
||||
|
* Copyright © 2016-2026 The Thingsboard Authors |
||||
|
* |
||||
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
||||
|
* you may not use this file except in compliance with the License. |
||||
|
* You may obtain a copy of the License at |
||||
|
* |
||||
|
* http://www.apache.org/licenses/LICENSE-2.0 |
||||
|
* |
||||
|
* Unless required by applicable law or agreed to in writing, software |
||||
|
* distributed under the License is distributed on an "AS IS" BASIS, |
||||
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
||||
|
* See the License for the specific language governing permissions and |
||||
|
* limitations under the License. |
||||
|
*/ |
||||
|
|
||||
|
@import "../../../../../scss/constants"; |
||||
|
|
||||
|
:host { |
||||
|
display: block; |
||||
|
width: 500px; |
||||
|
max-width: 100%; |
||||
|
} |
||||
|
|
||||
|
.tb-iot-hub-upgrade-required { |
||||
|
position: relative; |
||||
|
display: flex; |
||||
|
flex-direction: column; |
||||
|
align-items: center; |
||||
|
text-align: center; |
||||
|
gap: 20px; |
||||
|
padding: 40px; |
||||
|
background: white; |
||||
|
border-radius: 8px; |
||||
|
} |
||||
|
|
||||
|
.tb-iot-hub-upgrade-required-close { |
||||
|
position: absolute; |
||||
|
top: 8px; |
||||
|
right: 8px; |
||||
|
} |
||||
|
|
||||
|
// Re-use the upgrade-required.svg silhouette as a CSS mask so the icon |
||||
|
// tints with $tb-primary-color (PE overrides apply automatically). |
||||
|
.tb-iot-hub-upgrade-required-icon { |
||||
|
display: block; |
||||
|
width: 100px; |
||||
|
height: 100px; |
||||
|
background-color: $tb-primary-color; |
||||
|
-webkit-mask: url('/assets/iot-hub/upgrade-required.svg') no-repeat center / contain; |
||||
|
mask: url('/assets/iot-hub/upgrade-required.svg') no-repeat center / contain; |
||||
|
} |
||||
|
|
||||
|
.tb-iot-hub-upgrade-required-title { |
||||
|
font-size: 24px; |
||||
|
font-weight: 500; |
||||
|
line-height: 32px; |
||||
|
letter-spacing: 0.15px; |
||||
|
color: rgba(0, 0, 0, 0.87); |
||||
|
margin: 0; |
||||
|
} |
||||
|
|
||||
|
.tb-iot-hub-upgrade-required-message { |
||||
|
font-size: 14px; |
||||
|
font-weight: 400; |
||||
|
line-height: 24px; |
||||
|
letter-spacing: 0.25px; |
||||
|
color: rgba(0, 0, 0, 0.76); |
||||
|
margin: 0; |
||||
|
} |
||||
|
|
||||
|
.tb-iot-hub-upgrade-required-actions { |
||||
|
display: flex; |
||||
|
align-items: center; |
||||
|
gap: 8px; |
||||
|
} |
||||
@ -0,0 +1,59 @@ |
|||||
|
///
|
||||
|
/// Copyright © 2016-2026 The Thingsboard Authors
|
||||
|
///
|
||||
|
/// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
|
/// you may not use this file except in compliance with the License.
|
||||
|
/// You may obtain a copy of the License at
|
||||
|
///
|
||||
|
/// http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
///
|
||||
|
/// Unless required by applicable law or agreed to in writing, software
|
||||
|
/// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
|
/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
|
/// See the License for the specific language governing permissions and
|
||||
|
/// limitations under the License.
|
||||
|
///
|
||||
|
|
||||
|
import { Component, Inject } from '@angular/core'; |
||||
|
import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog'; |
||||
|
import { Router } from '@angular/router'; |
||||
|
import { Store } from '@ngrx/store'; |
||||
|
import { AppState } from '@core/core.state'; |
||||
|
import { DialogComponent } from '@shared/components/dialog.component'; |
||||
|
import { tbVersionIntToString } from '@core/http/iot-hub-api.service'; |
||||
|
import { environment as env } from '@env/environment'; |
||||
|
|
||||
|
export interface IotHubUpgradeRequiredDialogData { |
||||
|
minTbVersion: number; |
||||
|
} |
||||
|
|
||||
|
@Component({ |
||||
|
selector: 'tb-iot-hub-upgrade-required-dialog', |
||||
|
standalone: false, |
||||
|
templateUrl: './iot-hub-upgrade-required-dialog.component.html', |
||||
|
styleUrls: ['./iot-hub-upgrade-required-dialog.component.scss'] |
||||
|
}) |
||||
|
export class TbIotHubUpgradeRequiredDialogComponent extends DialogComponent<TbIotHubUpgradeRequiredDialogComponent> { |
||||
|
|
||||
|
readonly minVersion: string; |
||||
|
readonly currentVersion: string; |
||||
|
|
||||
|
constructor( |
||||
|
protected store: Store<AppState>, |
||||
|
protected router: Router, |
||||
|
protected dialogRef: MatDialogRef<TbIotHubUpgradeRequiredDialogComponent>, |
||||
|
@Inject(MAT_DIALOG_DATA) public data: IotHubUpgradeRequiredDialogData |
||||
|
) { |
||||
|
super(store, router, dialogRef); |
||||
|
this.minVersion = `v${tbVersionIntToString(data.minTbVersion)}`; |
||||
|
this.currentVersion = `v${env.tbVersion}`; |
||||
|
} |
||||
|
|
||||
|
close(): void { |
||||
|
this.dialogRef.close(); |
||||
|
} |
||||
|
|
||||
|
upgradeInstance(): void { |
||||
|
window.open('https://thingsboard.io/docs/installation/upgrade-instructions/', '_blank'); |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,52 @@ |
|||||
|
<!-- |
||||
|
|
||||
|
Copyright © 2016-2026 The Thingsboard Authors |
||||
|
|
||||
|
Licensed under the Apache License, Version 2.0 (the "License"); |
||||
|
you may not use this file except in compliance with the License. |
||||
|
You may obtain a copy of the License at |
||||
|
|
||||
|
http://www.apache.org/licenses/LICENSE-2.0 |
||||
|
|
||||
|
Unless required by applicable law or agreed to in writing, software |
||||
|
distributed under the License is distributed on an "AS IS" BASIS, |
||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
||||
|
See the License for the specific language governing permissions and |
||||
|
limitations under the License. |
||||
|
|
||||
|
--> |
||||
|
<div class="tb-iot-hub-alarm-rules-unavailable"> |
||||
|
<!-- Alarm-rules tinted glow blobs (same layout/colour rules as the |
||||
|
home page hero). --> |
||||
|
<div class="tb-iot-hub-blob tb-iot-hub-blob-left" [style.color]="alarmRulesColor"></div> |
||||
|
<div class="tb-iot-hub-blob tb-iot-hub-blob-right" [style.color]="alarmRulesColor"></div> |
||||
|
|
||||
|
<div class="tb-alarm-rules-banner-container"> |
||||
|
<div class="tb-alarm-rules-banner"> |
||||
|
<img class="tb-alarm-rules-banner-image" |
||||
|
src="assets/iot-hub/items-page-alarm-rules-hero.svg" alt=""> |
||||
|
|
||||
|
<h1 class="tb-alarm-rules-banner-title"> |
||||
|
{{ 'iot-hub.alarm-rules-unavailable-title-prefix' | translate }} |
||||
|
<span class="tb-alarm-rules-banner-version">{{ 'iot-hub.alarm-rules-unavailable-tb-version' | translate }}</span> |
||||
|
</h1> |
||||
|
|
||||
|
<p class="tb-alarm-rules-banner-desc"> |
||||
|
{{ 'iot-hub.alarm-rules-unavailable-desc' | translate }} |
||||
|
</p> |
||||
|
|
||||
|
<div class="tb-alarm-rules-banner-actions"> |
||||
|
<button mat-raised-button color="primary" (click)="upgradeInstance()"> |
||||
|
{{ 'iot-hub.alarm-rules-unavailable-upgrade' | translate }} |
||||
|
</button> |
||||
|
<button mat-stroked-button (click)="goBack()"> |
||||
|
{{ 'iot-hub.back-to-iot-hub' | translate }} |
||||
|
</button> |
||||
|
</div> |
||||
|
|
||||
|
<div class="tb-alarm-rules-banner-current"> |
||||
|
{{ 'iot-hub.alarm-rules-unavailable-current' | translate:{ version: currentTbVersion } }} |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
@ -0,0 +1,143 @@ |
|||||
|
/** |
||||
|
* Copyright © 2016-2026 The Thingsboard Authors |
||||
|
* |
||||
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
||||
|
* you may not use this file except in compliance with the License. |
||||
|
* You may obtain a copy of the License at |
||||
|
* |
||||
|
* http://www.apache.org/licenses/LICENSE-2.0 |
||||
|
* |
||||
|
* Unless required by applicable law or agreed to in writing, software |
||||
|
* distributed under the License is distributed on an "AS IS" BASIS, |
||||
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
||||
|
* See the License for the specific language governing permissions and |
||||
|
* limitations under the License. |
||||
|
*/ |
||||
|
|
||||
|
@import "../../../../../scss/constants"; |
||||
|
|
||||
|
// Outer page — 16px padding around the white container, matches |
||||
|
// iot-hub-home. |
||||
|
:host { |
||||
|
display: block; |
||||
|
padding: 16px; |
||||
|
height: 100%; |
||||
|
} |
||||
|
|
||||
|
// Page container — same white card / dot pattern / blob layering |
||||
|
// rules as the iot-hub home page. |
||||
|
.tb-iot-hub-alarm-rules-unavailable { |
||||
|
position: relative; |
||||
|
background: white; |
||||
|
border-radius: 8px; |
||||
|
overflow: hidden; |
||||
|
height: 100%; |
||||
|
|
||||
|
&::before { |
||||
|
content: ''; |
||||
|
position: absolute; |
||||
|
top: 0; |
||||
|
left: 0; |
||||
|
right: 0; |
||||
|
height: 800px; |
||||
|
background-image: radial-gradient(circle, rgba(0, 0, 0, 0.1) 1px, transparent 1px); |
||||
|
background-size: 20px 20px; |
||||
|
mask-image: linear-gradient(to bottom, black 0%, transparent 100%); |
||||
|
-webkit-mask-image: linear-gradient(to bottom, black 0%, transparent 100%); |
||||
|
pointer-events: none; |
||||
|
z-index: 1; |
||||
|
} |
||||
|
|
||||
|
> *:not(.tb-iot-hub-blob) { |
||||
|
position: relative; |
||||
|
z-index: 2; |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
// Soft colored glow blobs — copied verbatim from iot-hub-home so the |
||||
|
// page background matches. `color` is bound from the ALARM_RULE |
||||
|
// HeroTypeConfig entry. |
||||
|
.tb-iot-hub-blob { |
||||
|
position: absolute; |
||||
|
width: 568px; |
||||
|
height: 568px; |
||||
|
border-radius: 50%; |
||||
|
background: currentColor; |
||||
|
opacity: 0.16; |
||||
|
filter: blur(120px); |
||||
|
pointer-events: none; |
||||
|
z-index: 0; |
||||
|
} |
||||
|
|
||||
|
.tb-iot-hub-blob-left { |
||||
|
top: 56px; |
||||
|
left: -221px; |
||||
|
} |
||||
|
|
||||
|
.tb-iot-hub-blob-right { |
||||
|
top: 259px; |
||||
|
right: -196px; |
||||
|
} |
||||
|
|
||||
|
.tb-alarm-rules-banner-container { |
||||
|
height: 100%; |
||||
|
display: flex; |
||||
|
overflow-y: auto; |
||||
|
flex-direction: column; |
||||
|
} |
||||
|
|
||||
|
// Banner content stack — vertically centred in the card. |
||||
|
.tb-alarm-rules-banner { |
||||
|
display: flex; |
||||
|
flex-direction: column; |
||||
|
align-items: center; |
||||
|
text-align: center; |
||||
|
gap: 40px; |
||||
|
padding: 80px 40px; |
||||
|
margin: auto; |
||||
|
} |
||||
|
|
||||
|
.tb-alarm-rules-banner-image { |
||||
|
width: 446px; |
||||
|
max-width: 100%; |
||||
|
height: auto; |
||||
|
} |
||||
|
|
||||
|
.tb-alarm-rules-banner-title { |
||||
|
font-size: 28px; |
||||
|
font-weight: 500; |
||||
|
line-height: 36px; |
||||
|
letter-spacing: 0.15px; |
||||
|
color: rgba(0, 0, 0, 0.87); |
||||
|
margin: 0; |
||||
|
max-width: 900px; |
||||
|
} |
||||
|
|
||||
|
.tb-alarm-rules-banner-version { |
||||
|
color: $tb-primary-color; |
||||
|
} |
||||
|
|
||||
|
.tb-alarm-rules-banner-desc { |
||||
|
font-size: 16px; |
||||
|
font-weight: 400; |
||||
|
line-height: 24px; |
||||
|
letter-spacing: 0.15px; |
||||
|
color: rgba(0, 0, 0, 0.76); |
||||
|
margin: -24px 0 0; |
||||
|
max-width: 900px; |
||||
|
} |
||||
|
|
||||
|
.tb-alarm-rules-banner-actions { |
||||
|
display: flex; |
||||
|
align-items: center; |
||||
|
gap: 8px; |
||||
|
} |
||||
|
|
||||
|
.tb-alarm-rules-banner-current { |
||||
|
font-size: 12px; |
||||
|
font-weight: 400; |
||||
|
line-height: 16px; |
||||
|
letter-spacing: 0.4px; |
||||
|
color: rgba(0, 0, 0, 0.54); |
||||
|
margin-top: -28px; |
||||
|
} |
||||
@ -0,0 +1,43 @@ |
|||||
|
///
|
||||
|
/// Copyright © 2016-2026 The Thingsboard Authors
|
||||
|
///
|
||||
|
/// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
|
/// you may not use this file except in compliance with the License.
|
||||
|
/// You may obtain a copy of the License at
|
||||
|
///
|
||||
|
/// http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
///
|
||||
|
/// Unless required by applicable law or agreed to in writing, software
|
||||
|
/// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
|
/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
|
/// See the License for the specific language governing permissions and
|
||||
|
/// limitations under the License.
|
||||
|
///
|
||||
|
|
||||
|
import { Component } from '@angular/core'; |
||||
|
import { Router } from '@angular/router'; |
||||
|
import { environment as env } from '@env/environment'; |
||||
|
|
||||
|
@Component({ |
||||
|
selector: 'tb-iot-hub-alarm-rules-unavailable-page', |
||||
|
standalone: false, |
||||
|
templateUrl: './iot-hub-alarm-rules-unavailable-page.component.html', |
||||
|
styleUrls: ['./iot-hub-alarm-rules-unavailable-page.component.scss'] |
||||
|
}) |
||||
|
export class TbIotHubAlarmRulesUnavailablePageComponent { |
||||
|
|
||||
|
// Same colour as the ALARM_RULE HeroTypeConfig entry on the home page.
|
||||
|
readonly alarmRulesColor = '#d66f2e'; |
||||
|
|
||||
|
readonly currentTbVersion: string = env.tbVersion; |
||||
|
|
||||
|
constructor(private router: Router) {} |
||||
|
|
||||
|
goBack(): void { |
||||
|
void this.router.navigate(['/iot-hub']); |
||||
|
} |
||||
|
|
||||
|
upgradeInstance(): void { |
||||
|
window.open('https://thingsboard.io/docs/installation/upgrade-instructions/', '_blank'); |
||||
|
} |
||||
|
} |
||||
|
After Width: | Height: | Size: 827 B |
Loading…
Reference in new issue