File tree 3 files changed +39
-1
lines changed
pages/DeploySettingsPage/LicensesSettingsPage
3 files changed +39
-1
lines changed Original file line number Diff line number Diff line change @@ -329,6 +329,7 @@ type Claims = {
329
329
account_id ?: string ;
330
330
trial : boolean ;
331
331
all_features : boolean ;
332
+ feature_set : string ;
332
333
version : number ;
333
334
features : Record < string , number > ;
334
335
require_telemetry ?: boolean ;
Original file line number Diff line number Diff line change @@ -31,6 +31,12 @@ export const LicenseCard: FC<LicenseCardProps> = ({
31
31
const currentUserLimit =
32
32
license . claims . features [ "user_limit" ] || userLimitLimit ;
33
33
34
+ const licenseType = license . claims . trial
35
+ ? "Trial"
36
+ : license . claims . feature_set . toLowerCase ( ) === "premium"
37
+ ? "Premium"
38
+ : "Enterprise" ;
39
+
34
40
return (
35
41
< Paper
36
42
key = { license . id }
@@ -64,7 +70,7 @@ export const LicenseCard: FC<LicenseCardProps> = ({
64
70
>
65
71
< span css = { styles . licenseId } > #{ license . id } </ span >
66
72
< span css = { styles . accountType } className = "account-type" >
67
- { license . claims . trial ? "Trial" : "Enterprise" }
73
+ { licenseType }
68
74
</ span >
69
75
< Stack
70
76
direction = "row"
Original file line number Diff line number Diff line change @@ -2619,6 +2619,35 @@ export const MockLicenseResponse: GetLicensesResponse[] = [
2619
2619
claims : {
2620
2620
trial : false ,
2621
2621
all_features : true ,
2622
+ feature_set : "enterprise" ,
2623
+ version : 1 ,
2624
+ features : { } ,
2625
+ license_expires : 3420244800 ,
2626
+ } ,
2627
+ } ,
2628
+ {
2629
+ id : 1 ,
2630
+ uploaded_at : "1660104000" ,
2631
+ expires_at : "3420244800" , // expires on 5/20/2078
2632
+ uuid : "1" ,
2633
+ claims : {
2634
+ trial : false ,
2635
+ all_features : true ,
2636
+ feature_set : "PREMIUM" ,
2637
+ version : 1 ,
2638
+ features : { } ,
2639
+ license_expires : 3420244800 ,
2640
+ } ,
2641
+ } ,
2642
+ {
2643
+ id : 1 ,
2644
+ uploaded_at : "1660104000" ,
2645
+ expires_at : "3420244800" , // expires on 5/20/2078
2646
+ uuid : "1" ,
2647
+ claims : {
2648
+ trial : false ,
2649
+ all_features : true ,
2650
+ feature_set : "" , // Legacy is empty
2622
2651
version : 1 ,
2623
2652
features : { } ,
2624
2653
license_expires : 3420244800 ,
@@ -2632,6 +2661,7 @@ export const MockLicenseResponse: GetLicensesResponse[] = [
2632
2661
claims : {
2633
2662
trial : false ,
2634
2663
all_features : true ,
2664
+ feature_set : "" , // Legacy is empty
2635
2665
version : 1 ,
2636
2666
features : { } ,
2637
2667
license_expires : 1660104000 ,
@@ -2645,6 +2675,7 @@ export const MockLicenseResponse: GetLicensesResponse[] = [
2645
2675
claims : {
2646
2676
trial : false ,
2647
2677
all_features : true ,
2678
+ feature_set : "" , // Legacy is empty
2648
2679
version : 1 ,
2649
2680
features : { } ,
2650
2681
license_expires : 1682346425 ,
You can’t perform that action at this time.
0 commit comments