feat: multi-percentage monitors (per-core CPU), max 8
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.36.12
|
||||
// protoc v7.35.1
|
||||
// protoc v6.32.1
|
||||
// source: homelab/v1/homelab.proto
|
||||
|
||||
package homelabv1
|
||||
@@ -229,12 +229,14 @@ func (x *Stat) GetValue() string {
|
||||
return ""
|
||||
}
|
||||
|
||||
// Карточка монитора: процент (-1 = скрипт не дал процент) + строки для подписей.
|
||||
// Карточка монитора: проценты (-1 = скрипт не дал процент) + строки для подписей.
|
||||
// percentages[0] — основной (большой radial), дальше — дополнительные (per-core и т.п.).
|
||||
type Monitor struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
||||
Percentage int32 `protobuf:"varint,2,opt,name=percentage,proto3" json:"percentage,omitempty"`
|
||||
Stats []*Stat `protobuf:"bytes,3,rep,name=stats,proto3" json:"stats,omitempty"`
|
||||
Percentages []int32 `protobuf:"varint,4,rep,packed,name=percentages,proto3" json:"percentages,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
@@ -290,6 +292,13 @@ func (x *Monitor) GetStats() []*Stat {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *Monitor) GetPercentages() []int32 {
|
||||
if x != nil {
|
||||
return x.Percentages
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type Link struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
||||
@@ -1170,13 +1179,14 @@ const file_homelab_v1_homelab_proto_rawDesc = "" +
|
||||
"\targ_types\x18\x05 \x03(\tR\bargTypes\"0\n" +
|
||||
"\x04Stat\x12\x12\n" +
|
||||
"\x04name\x18\x01 \x01(\tR\x04name\x12\x14\n" +
|
||||
"\x05value\x18\x02 \x01(\tR\x05value\"e\n" +
|
||||
"\x05value\x18\x02 \x01(\tR\x05value\"\x87\x01\n" +
|
||||
"\aMonitor\x12\x12\n" +
|
||||
"\x04name\x18\x01 \x01(\tR\x04name\x12\x1e\n" +
|
||||
"\n" +
|
||||
"percentage\x18\x02 \x01(\x05R\n" +
|
||||
"percentage\x12&\n" +
|
||||
"\x05stats\x18\x03 \x03(\v2\x10.homelab.v1.StatR\x05stats\",\n" +
|
||||
"\x05stats\x18\x03 \x03(\v2\x10.homelab.v1.StatR\x05stats\x12 \n" +
|
||||
"\vpercentages\x18\x04 \x03(\x05R\vpercentages\",\n" +
|
||||
"\x04Link\x12\x12\n" +
|
||||
"\x04name\x18\x01 \x01(\tR\x04name\x12\x10\n" +
|
||||
"\x03url\x18\x02 \x01(\tR\x03url\"\x14\n" +
|
||||
|
||||
Reference in New Issue
Block a user